32 {
return ((
name[0] ==
'C') && (
name[1] == 0)); }
37 #if defined (_STLP_USE_MSVC6_MEM_T_BUG_WORKAROUND) || \ 38 defined (_STLP_SIGNAL_RUNTIME_COMPATIBILITY) || defined (_STLP_CHECK_RUNTIME_COMPATIBILITY) 39 # define locale _STLP_NO_MEM_T_NAME(loc) 44 #if !defined (_STLP_MEMBER_TEMPLATES) || defined (_STLP_INLINE_MEMBER_TEMPLATES) 47 const string& __y)
const 50 # if !defined (_STLP_NO_WCHAR_T) 52 const wstring& __y)
const 61 string what =
"Unable to find facet";
63 what +=
name.empty() ?
"system" :
name.c_str();
73 what =
"No platform localization support for ";
75 what +=
" facet category, unable to create facet for ";
76 what +=
name[0] == 0 ?
"system" :
name;
80 what =
"No platform localization support, unable to create ";
81 what +=
name[0] == 0 ?
"system" :
name;
86 what =
"Unable to create facet ";
88 what +=
" from name '";
103 if (
id._M_index == 0) {
104 #if defined (_STLP_ATOMIC_INCREMENT) && !defined (_STLP_WIN95_LIKE) 111 id._M_index = new_index;
153 const char* ctype_name =
name;
155 const char* numeric_name =
name;
157 const char* time_name =
name;
159 const char* collate_name =
name;
161 const char* monetary_name =
name;
163 const char* messages_name =
name;
174 if (
strcmp(ctype_name, numeric_name) == 0 &&
175 strcmp(ctype_name, time_name) == 0 &&
176 strcmp(ctype_name, collate_name) == 0 &&
177 strcmp(ctype_name, monetary_name) == 0 &&
178 strcmp(ctype_name, messages_name) == 0) {
179 impl->
name = ctype_name;
191 const char* ctype_name,
const char* time_name,
const char* numeric_name,
192 const char* collate_name,
const char* monetary_name,
const char* messages_name,
213 else if ((
c & locale::all) == locale::all)
222 const char* ctype_name,
const char* time_name,
const char* numeric_name,
223 const char* collate_name,
const char* monetary_name,
const char* messages_name,
225 if ((
c & locale::all) == 0 || (
strcmp(
name, ctype_name) == 0 &&
232 else if ((
c & locale::all) == locale::all &&
strcmp(ctype_name, time_name) == 0 &&
233 strcmp(ctype_name, numeric_name) == 0 &&
234 strcmp(ctype_name, collate_name) == 0 &&
235 strcmp(ctype_name, monetary_name) == 0 &&
236 strcmp(ctype_name, messages_name) == 0)
237 L->
name = ctype_name;
249 _M_throw_on_null_name();
260 const char* ctype_name =
name;
262 const char* numeric_name =
name;
264 const char* time_name =
name;
266 const char* collate_name =
name;
268 const char* monetary_name =
name;
270 const char* messages_name =
name;
272 if (
c & locale::ctype)
274 if (
c & locale::numeric)
278 if (
c & locale::collate)
280 if (
c & locale::monetary)
282 if (
c & locale::messages)
286 ctype_name, time_name, numeric_name,
287 collate_name, monetary_name, messages_name,
c);
309 # ifndef _STLP_NO_WCHAR_T 316 # ifndef _STLP_NO_WCHAR_T 326 # ifndef _STLP_NO_WCHAR_T 337 # ifndef _STLP_NO_WCHAR_T 346 # ifndef _STLP_NO_WCHAR_T 353 # ifndef _STLP_NO_WCHAR_T 369 if (this->_M_impl !=
L._M_impl) {
399 return !(*
this ==
L);
408 #if !defined (_STLP_USE_MSVC6_MEM_T_BUG_WORKAROUND) 420 #if !defined(_STLP_NO_LOCALE_SUPPORT) 426 #if !defined (_STLP_USE_MSVC6_MEM_T_BUG_WORKAROUND) 433 #if !defined (_STLP_STATIC_CONST_INIT_BUG) && !defined (_STLP_NO_STATIC_CONST_DEFINITION)
_Locale_name_hint * insert_numeric_facets(const char *&name, char *buf, _Locale_name_hint *hint)
char const * _Locale_extract_monetary_name(const char *cname, char *__buf, struct _Locale_name_hint *__hint, int *__err_code)
static void _Stl_loc_combine_names_aux(_Locale_impl *L, const char *name, const char *ctype_name, const char *time_name, const char *numeric_name, const char *collate_name, const char *monetary_name, const char *messages_name, locale::category c)
locale::facet * insert(locale::facet *, const locale::id &n)
basic_string< char, char_traits< char >, allocator< char > > name
static _STLP_BEGIN_NAMESPACE const string _Nameless("*")
#define _STLP_STATIC_MUTEX
static void _Stl_loc_combine_names(_Locale_impl *L, const char *name1, const char *name2, locale::category c)
static void _STLP_FUNCTION_THROWS _STLP_CALL _M_throw_on_combine_error(const string &name)
#define __STATIC_CAST(__x, __y)
void _STLP_CALL _release_Locale_impl(_Locale_impl *&loc)
_Locale_name_hint * insert_monetary_facets(const char *&name, char *buf, _Locale_name_hint *hint)
locale * _Stl_get_classic_locale()
char const * _Locale_extract_time_name(const char *cname, char *__buf, struct _Locale_name_hint *__hint, int *__err_code)
static void _STLP_FUNCTION_THROWS _STLP_CALL _M_throw_bad_cast()
GLenum GLuint GLenum GLsizei const GLchar * buf
bool operator()(const string &__x, const string &__y) const
char const * _Locale_extract_collate_name(const char *cname, char *__buf, struct _Locale_name_hint *__hint, int *__err_code)
#define _STLP_LOC_NO_PLATFORM_SUPPORT
static const locale &_STLP_CALL classic()
char const * _Locale_extract_ctype_name(const char *cname, char *__buf, struct _Locale_name_hint *__hint, int *__err_code)
#define _STLP_LOC_NO_MEMORY
static void _STLP_FUNCTION_THROWS _STLP_CALL _M_throw_on_creation_failure(int __err_code, const char *name, const char *facet)
#define _STLP_UNWIND(action)
bool operator!=(const locale &) const
const _CharT * c_str() const
_Locale_name_hint * insert_collate_facets(const char *&name, char *buf, _Locale_name_hint *hint)
_STLP_DECLSPEC _Locale_impl *_STLP_CALL _get_Locale_impl(_Locale_impl *locimpl)
const locale & operator=(const locale &) _STLP_NOTHROW
vector< locale::facet * > facets_vec
_Locale_name_hint * insert_time_facets(const char *&name, char *buf, _Locale_name_hint *hint)
facet * _M_get_facet(const id &) const
_Locale_name_hint * insert_ctype_facets(const char *&name, char *buf, _Locale_name_hint *hint)
friend class _Locale_impl
void _M_insert(facet *__f, id &__id)
_Locale_name_hint * insert_messages_facets(const char *&name, char *buf, _Locale_name_hint *hint)
static void _STLP_FUNCTION_THROWS _STLP_CALL _M_throw_on_null_name()
static bool is_C_locale_name(const char *name)
#define _STLP_LOC_UNKNOWN_NAME
locale * _Stl_get_global_locale()
char const * _Locale_extract_numeric_name(const char *cname, char *__buf, struct _Locale_name_hint *__hint, int *__err_code)
#define _Locale_MAX_SIMPLE_NAME
#define _STLP_MUTEX_INITIALIZER
static const locale::id & _Stl_loc_get_index(locale::id &id)
static locale _STLP_CALL global(const locale &)
#define _STLP_END_NAMESPACE
bool operator==(const locale &) const
#define _STLP_LOC_UNSUPPORTED_FACET_CATEGORY
char const * _Locale_extract_messages_name(const char *cname, char *__buf, struct _Locale_name_hint *__hint, int *__err_code)
int strcmp(const char *String1, const char *String2)
#define _STLP_BEGIN_NAMESPACE
#define _STLP_THROW_BAD_ALLOC
bool __locale_do_operator_call(const locale &__loc, const basic_string< _CharT, _Traits, _Alloc > &__x, const basic_string< _CharT, _Traits, _Alloc > &__y)
facet * _M_use_facet(const id &) const
#define _STLP_ATOMIC_INCREMENT(__x)
GLuint const GLchar * name