32 #ifndef _LOCALE_FACETS_TCC
33 #define _LOCALE_FACETS_TCC 1
35 #pragma GCC system_header
37 namespace std _GLIBCXX_VISIBILITY(default)
39 _GLIBCXX_BEGIN_NAMESPACE_VERSION
43 template<
typename _Facet>
47 operator() (
const locale& __loc)
const;
51 template<
typename _CharT>
52 struct __use_cache<__numpunct_cache<_CharT> >
54 const __numpunct_cache<_CharT>*
55 operator() (
const locale& __loc)
const
57 const size_t __i = numpunct<_CharT>::id._M_id();
58 const locale::facet** __caches = __loc._M_impl->_M_caches;
61 __numpunct_cache<_CharT>* __tmp = 0;
64 __tmp =
new __numpunct_cache<_CharT>;
65 __tmp->_M_cache(__loc);
70 __throw_exception_again;
72 __loc._M_impl->_M_install_cache(__tmp, __i);
74 return static_cast<const __numpunct_cache<_CharT>*
>(__caches[__i]);
78 template<
typename _CharT>
80 __numpunct_cache<_CharT>::_M_cache(
const locale& __loc)
84 const numpunct<_CharT>& __np = use_facet<numpunct<_CharT> >(__loc);
87 _CharT* __truename = 0;
88 _CharT* __falsename = 0;
91 _M_grouping_size = __np.grouping().size();
92 __grouping =
new char[_M_grouping_size];
93 __np.grouping().copy(__grouping, _M_grouping_size);
94 _M_grouping = __grouping;
95 _M_use_grouping = (_M_grouping_size
96 &&
static_cast<signed char>(_M_grouping[0]) > 0
98 != __gnu_cxx::__numeric_traits<char>::__max));
100 _M_truename_size = __np.truename().size();
101 __truename =
new _CharT[_M_truename_size];
102 __np.truename().copy(__truename, _M_truename_size);
103 _M_truename = __truename;
105 _M_falsename_size = __np.falsename().size();
106 __falsename =
new _CharT[_M_falsename_size];
107 __np.falsename().copy(__falsename, _M_falsename_size);
108 _M_falsename = __falsename;
110 _M_decimal_point = __np.decimal_point();
111 _M_thousands_sep = __np.thousands_sep();
113 const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__loc);
114 __ct.widen(__num_base::_S_atoms_out,
115 __num_base::_S_atoms_out
116 + __num_base::_S_oend, _M_atoms_out);
117 __ct.widen(__num_base::_S_atoms_in,
118 __num_base::_S_atoms_in
119 + __num_base::_S_iend, _M_atoms_in);
123 delete [] __grouping;
124 delete [] __truename;
125 delete [] __falsename;
126 __throw_exception_again;
139 __verify_grouping(
const char* __grouping,
size_t __grouping_size,
140 const string& __grouping_tmp)
throw ();
142 _GLIBCXX_BEGIN_NAMESPACE_LDBL
144 template<
typename _CharT,
typename _InIter>
146 num_get<_CharT, _InIter>::
147 _M_extract_float(_InIter __beg, _InIter __end, ios_base& __io,
150 typedef char_traits<_CharT> __traits_type;
151 typedef __numpunct_cache<_CharT> __cache_type;
152 __use_cache<__cache_type> __uc;
153 const locale& __loc = __io._M_getloc();
154 const __cache_type* __lc = __uc(__loc);
155 const _CharT* __lit = __lc->_M_atoms_in;
156 char_type __c = char_type();
159 bool __testeof = __beg == __end;
165 const bool __plus = __c == __lit[__num_base::_S_iplus];
166 if ((__plus || __c == __lit[__num_base::_S_iminus])
167 && !(__lc->_M_use_grouping && __c == __lc->_M_thousands_sep)
168 && !(__c == __lc->_M_decimal_point))
170 __xtrc += __plus ?
'+' :
'-';
171 if (++__beg != __end)
179 bool __found_mantissa =
false;
183 if ((__lc->_M_use_grouping && __c == __lc->_M_thousands_sep)
184 || __c == __lc->_M_decimal_point)
186 else if (__c == __lit[__num_base::_S_izero])
188 if (!__found_mantissa)
191 __found_mantissa =
true;
195 if (++__beg != __end)
205 bool __found_dec =
false;
206 bool __found_sci =
false;
207 string __found_grouping;
208 if (__lc->_M_use_grouping)
209 __found_grouping.reserve(32);
210 const char_type* __lit_zero = __lit + __num_base::_S_izero;
212 if (!__lc->_M_allocated)
216 const int __digit = _M_find(__lit_zero, 10, __c);
219 __xtrc +=
'0' + __digit;
220 __found_mantissa =
true;
222 else if (__c == __lc->_M_decimal_point
223 && !__found_dec && !__found_sci)
228 else if ((__c == __lit[__num_base::_S_ie]
229 || __c == __lit[__num_base::_S_iE])
230 && !__found_sci && __found_mantissa)
237 if (++__beg != __end)
240 const bool __plus = __c == __lit[__num_base::_S_iplus];
241 if (__plus || __c == __lit[__num_base::_S_iminus])
242 __xtrc += __plus ?
'+' :
'-';
255 if (++__beg != __end)
265 if (__lc->_M_use_grouping && __c == __lc->_M_thousands_sep)
267 if (!__found_dec && !__found_sci)
273 __found_grouping +=
static_cast<char>(__sep_pos);
287 else if (__c == __lc->_M_decimal_point)
289 if (!__found_dec && !__found_sci)
294 if (__found_grouping.size())
295 __found_grouping += static_cast<char>(__sep_pos);
304 const char_type* __q =
305 __traits_type::find(__lit_zero, 10, __c);
308 __xtrc +=
'0' + (__q - __lit_zero);
309 __found_mantissa =
true;
312 else if ((__c == __lit[__num_base::_S_ie]
313 || __c == __lit[__num_base::_S_iE])
314 && !__found_sci && __found_mantissa)
317 if (__found_grouping.size() && !__found_dec)
318 __found_grouping += static_cast<char>(__sep_pos);
323 if (++__beg != __end)
326 const bool __plus = __c == __lit[__num_base::_S_iplus];
327 if ((__plus || __c == __lit[__num_base::_S_iminus])
328 && !(__lc->_M_use_grouping
329 && __c == __lc->_M_thousands_sep)
330 && !(__c == __lc->_M_decimal_point))
331 __xtrc += __plus ?
'+' :
'-';
345 if (++__beg != __end)
353 if (__found_grouping.size())
356 if (!__found_dec && !__found_sci)
357 __found_grouping +=
static_cast<char>(__sep_pos);
359 if (!std::__verify_grouping(__lc->_M_grouping,
360 __lc->_M_grouping_size,
368 template<
typename _CharT,
typename _InIter>
369 template<
typename _ValueT>
371 num_get<_CharT, _InIter>::
372 _M_extract_int(_InIter __beg, _InIter __end, ios_base& __io,
375 typedef char_traits<_CharT> __traits_type;
376 using __gnu_cxx::__add_unsigned;
377 typedef typename __add_unsigned<_ValueT>::__type __unsigned_type;
378 typedef __numpunct_cache<_CharT> __cache_type;
379 __use_cache<__cache_type> __uc;
380 const locale& __loc = __io._M_getloc();
381 const __cache_type* __lc = __uc(__loc);
382 const _CharT* __lit = __lc->_M_atoms_in;
383 char_type __c = char_type();
392 bool __testeof = __beg == __end;
395 bool __negative =
false;
399 __negative = __c == __lit[__num_base::_S_iminus];
400 if ((__negative || __c == __lit[__num_base::_S_iplus])
401 && !(__lc->_M_use_grouping && __c == __lc->_M_thousands_sep)
402 && !(__c == __lc->_M_decimal_point))
404 if (++__beg != __end)
413 bool __found_zero =
false;
417 if ((__lc->_M_use_grouping && __c == __lc->_M_thousands_sep)
418 || __c == __lc->_M_decimal_point)
420 else if (__c == __lit[__num_base::_S_izero]
421 && (!__found_zero || __base == 10))
425 if (__basefield == 0)
430 else if (__found_zero
431 && (__c == __lit[__num_base::_S_ix]
432 || __c == __lit[__num_base::_S_iX]))
434 if (__basefield == 0)
438 __found_zero =
false;
447 if (++__beg != __end)
459 const size_t __len = (__base == 16 ? __num_base::_S_iend
460 - __num_base::_S_izero :
__base);
463 string __found_grouping;
464 if (__lc->_M_use_grouping)
465 __found_grouping.reserve(32);
466 bool __testfail =
false;
467 bool __testoverflow =
false;
468 const __unsigned_type __max =
469 (__negative && __gnu_cxx::__numeric_traits<_ValueT>::__is_signed)
470 ? -__gnu_cxx::__numeric_traits<_ValueT>::__min
471 : __gnu_cxx::__numeric_traits<_ValueT>::__max;
472 const __unsigned_type __smax = __max /
__base;
473 __unsigned_type __result = 0;
475 const char_type* __lit_zero = __lit + __num_base::_S_izero;
477 if (!__lc->_M_allocated)
481 __digit = _M_find(__lit_zero, __len, __c);
485 if (__result > __smax)
486 __testoverflow =
true;
490 __testoverflow |= __result > __max - __digit;
495 if (++__beg != __end)
505 if (__lc->_M_use_grouping && __c == __lc->_M_thousands_sep)
511 __found_grouping +=
static_cast<char>(__sep_pos);
520 else if (__c == __lc->_M_decimal_point)
524 const char_type* __q =
525 __traits_type::find(__lit_zero, __len, __c);
529 __digit = __q - __lit_zero;
532 if (__result > __smax)
533 __testoverflow =
true;
537 __testoverflow |= __result > __max - __digit;
543 if (++__beg != __end)
551 if (__found_grouping.size())
554 __found_grouping +=
static_cast<char>(__sep_pos);
556 if (!std::__verify_grouping(__lc->_M_grouping,
557 __lc->_M_grouping_size,
564 if ((!__sep_pos && !__found_zero && !__found_grouping.size())
570 else if (__testoverflow)
573 && __gnu_cxx::__numeric_traits<_ValueT>::__is_signed)
574 __v = __gnu_cxx::__numeric_traits<_ValueT>::__min;
576 __v = __gnu_cxx::__numeric_traits<_ValueT>::__max;
580 __v = __negative ? -__result : __result;
589 template<
typename _CharT,
typename _InIter>
593 ios_base::iostate& __err,
bool& __v)
const
601 __beg = _M_extract_int(__beg, __end, __io, __err, __l);
602 if (__l == 0 || __l == 1)
617 typedef __numpunct_cache<_CharT> __cache_type;
618 __use_cache<__cache_type> __uc;
620 const __cache_type* __lc = __uc(__loc);
624 bool __donef = __lc->_M_falsename_size == 0;
625 bool __donet = __lc->_M_truename_size == 0;
626 bool __testeof =
false;
628 while (!__donef || !__donet)
639 __testf = __c == __lc->_M_falsename[__n];
641 if (!__testf && __donet)
645 __testt = __c == __lc->_M_truename[__n];
647 if (!__testt && __donef)
650 if (!__testt && !__testf)
656 __donef = !__testf || __n >= __lc->_M_falsename_size;
657 __donet = !__testt || __n >= __lc->_M_truename_size;
659 if (__testf && __n == __lc->_M_falsename_size && __n)
662 if (__testt && __n == __lc->_M_truename_size)
667 else if (__testt && __n == __lc->_M_truename_size && __n)
685 template<
typename _CharT,
typename _InIter>
689 ios_base::iostate& __err,
float& __v)
const
693 __beg = _M_extract_float(__beg, __end, __io, __err, __xtrc);
694 std::__convert_to_v(__xtrc.
c_str(), __v, __err, _S_get_c_locale());
700 template<
typename _CharT,
typename _InIter>
704 ios_base::iostate& __err,
double& __v)
const
708 __beg = _M_extract_float(__beg, __end, __io, __err, __xtrc);
709 std::__convert_to_v(__xtrc.
c_str(), __v, __err, _S_get_c_locale());
715 #if defined _GLIBCXX_LONG_DOUBLE_COMPAT && defined __LONG_DOUBLE_128__
716 template<
typename _CharT,
typename _InIter>
720 ios_base::iostate& __err,
double& __v)
const
724 __beg = _M_extract_float(__beg, __end, __io, __err, __xtrc);
725 std::__convert_to_v(__xtrc.
c_str(), __v, __err, _S_get_c_locale());
732 template<
typename _CharT,
typename _InIter>
736 ios_base::iostate& __err,
long double& __v)
const
740 __beg = _M_extract_float(__beg, __end, __io, __err, __xtrc);
741 std::__convert_to_v(__xtrc.
c_str(), __v, __err, _S_get_c_locale());
747 template<
typename _CharT,
typename _InIter>
751 ios_base::iostate& __err,
void*& __v)
const
754 typedef ios_base::fmtflags fmtflags;
755 const fmtflags __fmt = __io.
flags();
758 typedef __gnu_cxx::__conditional_type<(
sizeof(
void*)
759 <=
sizeof(
unsigned long)),
760 unsigned long,
unsigned long long>::__type _UIntPtrType;
763 __beg = _M_extract_int(__beg, __end, __io, __err, __ul);
768 __v =
reinterpret_cast<void*
>(__ul);
774 template<
typename _CharT,
typename _OutIter>
778 _CharT* __new,
const _CharT* __cs,
int& __len)
const
782 __pad<_CharT, char_traits<_CharT> >::_S_pad(__io, __fill, __new,
784 __len =
static_cast<int>(__w);
787 _GLIBCXX_END_NAMESPACE_LDBL
789 template<
typename _CharT,
typename _ValueT>
791 __int_to_char(_CharT* __bufend, _ValueT __v,
const _CharT* __lit,
794 _CharT* __buf = __bufend;
795 if (__builtin_expect(__dec,
true))
800 *--__buf = __lit[(__v % 10) + __num_base::_S_odigits];
810 *--__buf = __lit[(__v & 0x7) + __num_base::_S_odigits];
819 const int __case_offset = __uppercase ? __num_base::_S_oudigits
820 : __num_base::_S_odigits;
823 *--__buf = __lit[(__v & 0xf) + __case_offset];
828 return __bufend - __buf;
831 _GLIBCXX_BEGIN_NAMESPACE_LDBL
833 template<
typename _CharT,
typename _OutIter>
835 num_put<_CharT, _OutIter>::
836 _M_group_int(
const char* __grouping,
size_t __grouping_size, _CharT __sep,
837 ios_base&, _CharT* __new, _CharT* __cs,
int& __len)
const
839 _CharT* __p = std::__add_grouping(__new, __sep, __grouping,
840 __grouping_size, __cs, __cs + __len);
844 template<
typename _CharT,
typename _OutIter>
845 template<
typename _ValueT>
847 num_put<_CharT, _OutIter>::
848 _M_insert_int(_OutIter __s, ios_base& __io, _CharT __fill,
851 using __gnu_cxx::__add_unsigned;
852 typedef typename __add_unsigned<_ValueT>::__type __unsigned_type;
853 typedef __numpunct_cache<_CharT> __cache_type;
854 __use_cache<__cache_type> __uc;
855 const locale& __loc = __io._M_getloc();
856 const __cache_type* __lc = __uc(__loc);
857 const _CharT* __lit = __lc->_M_atoms_out;
861 const int __ilen = 5 *
sizeof(_ValueT);
862 _CharT* __cs =
static_cast<_CharT*
>(__builtin_alloca(
sizeof(_CharT)
870 const __unsigned_type __u = ((__v > 0 || !__dec)
871 ? __unsigned_type(__v)
872 : -__unsigned_type(__v));
873 int __len = __int_to_char(__cs + __ilen, __u, __lit, __flags, __dec);
874 __cs += __ilen - __len;
877 if (__lc->_M_use_grouping)
881 _CharT* __cs2 =
static_cast<_CharT*
>(__builtin_alloca(
sizeof(_CharT)
884 _M_group_int(__lc->_M_grouping, __lc->_M_grouping_size,
885 __lc->_M_thousands_sep, __io, __cs2 + 2, __cs, __len);
890 if (__builtin_expect(__dec,
true))
896 && __gnu_cxx::__numeric_traits<_ValueT>::__is_signed)
897 *--__cs = __lit[__num_base::_S_oplus], ++__len;
900 *--__cs = __lit[__num_base::_S_ominus], ++__len;
905 *--__cs = __lit[__num_base::_S_odigits], ++__len;
910 *--__cs = __lit[__num_base::_S_ox + __uppercase];
912 *--__cs = __lit[__num_base::_S_odigits];
919 if (__w > static_cast<streamsize>(__len))
921 _CharT* __cs3 =
static_cast<_CharT*
>(__builtin_alloca(
sizeof(_CharT)
923 _M_pad(__fill, __w, __io, __cs3, __cs, __len);
930 return std::__write(__s, __cs, __len);
933 template<
typename _CharT,
typename _OutIter>
935 num_put<_CharT, _OutIter>::
936 _M_group_float(
const char* __grouping,
size_t __grouping_size,
937 _CharT __sep,
const _CharT* __p, _CharT* __new,
938 _CharT* __cs,
int& __len)
const
943 const int __declen = __p ? __p - __cs : __len;
944 _CharT* __p2 = std::__add_grouping(__new, __sep, __grouping,
946 __cs, __cs + __declen);
949 int __newlen = __p2 - __new;
952 char_traits<_CharT>::copy(__p2, __p, __len - __declen);
953 __newlen += __len - __declen;
968 template<
typename _CharT,
typename _OutIter>
969 template<
typename _ValueT>
971 num_put<_CharT, _OutIter>::
972 _M_insert_float(_OutIter __s, ios_base& __io, _CharT __fill,
char __mod,
975 typedef __numpunct_cache<_CharT> __cache_type;
976 __use_cache<__cache_type> __uc;
977 const locale& __loc = __io._M_getloc();
978 const __cache_type* __lc = __uc(__loc);
981 const streamsize __prec = __io.precision() < 0 ? 6 : __io.precision();
983 const int __max_digits =
984 __gnu_cxx::__numeric_traits<_ValueT>::__digits10;
990 __num_base::_S_format_float(__io, __fbuf, __mod);
992 #ifdef _GLIBCXX_USE_C99
995 int __cs_size = __max_digits * 3;
996 char* __cs =
static_cast<char*
>(__builtin_alloca(__cs_size));
997 __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size,
998 __fbuf, __prec, __v);
1001 if (__len >= __cs_size)
1003 __cs_size = __len + 1;
1004 __cs =
static_cast<char*
>(__builtin_alloca(__cs_size));
1005 __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size,
1006 __fbuf, __prec, __v);
1011 const int __max_exp =
1012 __gnu_cxx::__numeric_traits<_ValueT>::__max_exponent10;
1020 const int __cs_size = __fixed ? __max_exp + __prec + 4
1021 : __max_digits * 2 + __prec;
1022 char* __cs =
static_cast<char*
>(__builtin_alloca(__cs_size));
1023 __len = std::__convert_from_v(_S_get_c_locale(), __cs, 0, __fbuf,
1029 const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc);
1031 _CharT* __ws =
static_cast<_CharT*
>(__builtin_alloca(
sizeof(_CharT)
1033 __ctype.widen(__cs, __cs + __len, __ws);
1037 const char* __p = char_traits<char>::find(__cs, __len,
'.');
1040 __wp = __ws + (__p - __cs);
1041 *__wp = __lc->_M_decimal_point;
1047 if (__lc->_M_use_grouping
1048 && (__wp || __len < 3 || (__cs[1] <=
'9' && __cs[2] <=
'9'
1049 && __cs[1] >=
'0' && __cs[2] >=
'0')))
1053 _CharT* __ws2 =
static_cast<_CharT*
>(__builtin_alloca(
sizeof(_CharT)
1057 if (__cs[0] ==
'-' || __cs[0] ==
'+')
1064 _M_group_float(__lc->_M_grouping, __lc->_M_grouping_size,
1065 __lc->_M_thousands_sep, __wp, __ws2 + __off,
1066 __ws + __off, __len);
1074 if (__w > static_cast<streamsize>(__len))
1076 _CharT* __ws3 =
static_cast<_CharT*
>(__builtin_alloca(
sizeof(_CharT)
1078 _M_pad(__fill, __w, __io, __ws3, __ws, __len);
1085 return std::__write(__s, __ws, __len);
1088 template<
typename _CharT,
typename _OutIter>
1093 const ios_base::fmtflags __flags = __io.
flags();
1096 const long __l = __v;
1097 __s = _M_insert_int(__s, __io, __fill, __l);
1101 typedef __numpunct_cache<_CharT> __cache_type;
1102 __use_cache<__cache_type> __uc;
1104 const __cache_type* __lc = __uc(__loc);
1106 const _CharT* __name = __v ? __lc->_M_truename
1107 : __lc->_M_falsename;
1108 int __len = __v ? __lc->_M_truename_size
1109 : __lc->_M_falsename_size;
1112 if (__w > static_cast<streamsize>(__len))
1116 =
static_cast<_CharT*
>(__builtin_alloca(
sizeof(_CharT)
1124 __s = std::__write(__s, __name, __len);
1125 __s = std::__write(__s, __ps, __plen);
1129 __s = std::__write(__s, __ps, __plen);
1130 __s = std::__write(__s, __name, __len);
1135 __s = std::__write(__s, __name, __len);
1140 template<
typename _CharT,
typename _OutIter>
1144 {
return _M_insert_float(__s, __io, __fill,
char(), __v); }
1146 #if defined _GLIBCXX_LONG_DOUBLE_COMPAT && defined __LONG_DOUBLE_128__
1147 template<
typename _CharT,
typename _OutIter>
1150 __do_put(iter_type __s,
ios_base& __io, char_type __fill,
double __v)
const
1151 {
return _M_insert_float(__s, __io, __fill,
char(), __v); }
1154 template<
typename _CharT,
typename _OutIter>
1158 long double __v)
const
1159 {
return _M_insert_float(__s, __io, __fill,
'L', __v); }
1161 template<
typename _CharT,
typename _OutIter>
1165 const void* __v)
const
1167 const ios_base::fmtflags __flags = __io.
flags();
1168 const ios_base::fmtflags __fmt = ~(ios_base::basefield
1172 typedef __gnu_cxx::__conditional_type<(
sizeof(
const void*)
1173 <=
sizeof(
unsigned long)),
1174 unsigned long,
unsigned long long>::__type _UIntPtrType;
1176 __s = _M_insert_int(__s, __io, __fill,
1177 reinterpret_cast<_UIntPtrType>(__v));
1178 __io.
flags(__flags);
1182 _GLIBCXX_END_NAMESPACE_LDBL
1191 template<
typename _CharT,
typename _Traits>
1193 __pad<_CharT, _Traits>::_S_pad(
ios_base& __io, _CharT __fill,
1194 _CharT* __news,
const _CharT* __olds,
1197 const size_t __plen =
static_cast<size_t>(__newlen - __oldlen);
1203 _Traits::copy(__news, __olds, __oldlen);
1204 _Traits::assign(__news + __oldlen, __plen, __fill);
1215 const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc);
1217 if (__ctype.widen(
'-') == __olds[0]
1218 || __ctype.widen(
'+') == __olds[0])
1220 __news[0] = __olds[0];
1224 else if (__ctype.widen(
'0') == __olds[0]
1226 && (__ctype.widen(
'x') == __olds[1]
1227 || __ctype.widen(
'X') == __olds[1]))
1229 __news[0] = __olds[0];
1230 __news[1] = __olds[1];
1236 _Traits::assign(__news, __plen, __fill);
1237 _Traits::copy(__news + __plen, __olds + __mod, __oldlen - __mod);
1240 template<
typename _CharT>
1242 __add_grouping(_CharT* __s, _CharT __sep,
1243 const char* __gbeg,
size_t __gsize,
1244 const _CharT* __first,
const _CharT* __last)
1249 while (__last - __first > __gbeg[__idx]
1250 && static_cast<signed char>(__gbeg[__idx]) > 0
1251 && __gbeg[__idx] != __gnu_cxx::__numeric_traits<char>::__max)
1253 __last -= __gbeg[__idx];
1254 __idx < __gsize - 1 ? ++__idx : ++__ctr;
1257 while (__first != __last)
1258 *__s++ = *__first++;
1263 for (
char __i = __gbeg[__idx]; __i > 0; --__i)
1264 *__s++ = *__first++;
1270 for (
char __i = __gbeg[__idx]; __i > 0; --__i)
1271 *__s++ = *__first++;
1279 #if _GLIBCXX_EXTERN_TEMPLATE
1280 extern template class numpunct<char>;
1281 extern template class numpunct_byname<char>;
1282 extern template class _GLIBCXX_NAMESPACE_LDBL num_get<char>;
1283 extern template class _GLIBCXX_NAMESPACE_LDBL num_put<char>;
1284 extern template class ctype_byname<char>;
1288 use_facet<ctype<char> >(
const locale&);
1291 const numpunct<char>&
1292 use_facet<numpunct<char> >(
const locale&);
1295 const num_put<char>&
1296 use_facet<num_put<char> >(
const locale&);
1299 const num_get<char>&
1300 use_facet<num_get<char> >(
const locale&);
1304 has_facet<ctype<char> >(
const locale&);
1308 has_facet<numpunct<char> >(
const locale&);
1312 has_facet<num_put<char> >(
const locale&);
1316 has_facet<num_get<char> >(
const locale&);
1318 #ifdef _GLIBCXX_USE_WCHAR_T
1319 extern template class numpunct<wchar_t>;
1320 extern template class numpunct_byname<wchar_t>;
1321 extern template class _GLIBCXX_NAMESPACE_LDBL num_get<wchar_t>;
1322 extern template class _GLIBCXX_NAMESPACE_LDBL num_put<wchar_t>;
1323 extern template class ctype_byname<wchar_t>;
1326 const ctype<wchar_t>&
1327 use_facet<ctype<wchar_t> >(
const locale&);
1330 const numpunct<wchar_t>&
1331 use_facet<numpunct<wchar_t> >(
const locale&);
1334 const num_put<wchar_t>&
1335 use_facet<num_put<wchar_t> >(
const locale&);
1338 const num_get<wchar_t>&
1339 use_facet<num_get<wchar_t> >(
const locale&);
1343 has_facet<ctype<wchar_t> >(
const locale&);
1347 has_facet<numpunct<wchar_t> >(
const locale&);
1351 has_facet<num_put<wchar_t> >(
const locale&);
1355 has_facet<num_get<wchar_t> >(
const locale&);
1359 _GLIBCXX_END_NAMESPACE_VERSION