Remove trailing whitespace from libstdc++-v3 files

2016-04-29  Chris Gregory  <czipperz@gmail.com>

	* config/*: Remove trailing whitespace.
	* src/*: Likewise.
	* testsuite/tr1/*: Likewise.
	* testsuite/util/*: Likewise.

From-SVN: r235645
This commit is contained in:
Chris Gregory 2016-04-29 16:11:43 +00:00 committed by Jonathan Wakely
parent 8960db3195
commit f92ab29ffa
471 changed files with 12489 additions and 12482 deletions

View File

@ -1,3 +1,10 @@
2016-04-29 Chris Gregory <czipperz@gmail.com>
* config/*: Remove trailing whitespace.
* src/*: Likewise.
* testsuite/tr1/*: Likewise.
* testsuite/util/*: Likewise.
2016-04-28 Jonathan Wakely <jwakely@redhat.com>
PR libstdc++/70766

View File

@ -28,7 +28,7 @@
*/
// Switch for symbol version macro.
#ifndef _GLIBCXX_APPLY_SYMVER
#ifndef _GLIBCXX_APPLY_SYMVER
#error must define _GLIBCXX_APPLY_SYMVER before including __FILE__
#endif
@ -36,7 +36,7 @@
_ZNSt19istreambuf_iteratorIcSt11char_traitsIcEEppEv
_ZNSt19istreambuf_iteratorIwSt11char_traitsIwEEppEv
*/
namespace
namespace
{
_GLIBCXX_APPLY_SYMVER(_ZNSt21istreambuf_iteratorXXIcSt11char_traitsIcEEppEv,
_ZNSt19istreambuf_iteratorIcSt11char_traitsIcEEppEv)
@ -76,7 +76,7 @@ _ZNSt13basic_istreamIwSt11char_traitsIwEE6ignoreEv
_ZNSt11char_traitsIcE2eqERKcS2_
_ZNSt11char_traitsIwE2eqERKwS2_
*/
namespace
namespace
{
_GLIBCXX_APPLY_SYMVER(_ZNSt11char_traitsIcE4eqXXERKcS2_,
_ZNSt11char_traitsIcE2eqERKcS2_)

View File

@ -77,7 +77,7 @@ GLIBCXX_7.0 {
# locale
_ZNSt3__79has_facetINS_*;
# hash
# hash
_ZNSt8__detail3__712__prime_listE;
_ZNSt3tr18__detail3__712__prime_listE;
@ -110,7 +110,7 @@ GLIBCXX_7.0 {
_ZN9__gnu_cxx3__76__poolILb[01]EE10_M_destroyEv;
_ZN9__gnu_cxx3__76__poolILb1EE16_M_get_thread_idEv;
_ZN9__gnu_cxx3__717__pool_alloc_base9_M_refillE[jmy];
_ZN9__gnu_cxx3__717__pool_alloc_base9_M_refillE[jmy];
_ZN9__gnu_cxx3__717__pool_alloc_base16_M_get_free_listE[jmy];
_ZN9__gnu_cxx3__717__pool_alloc_base12_M_get_mutexEv;

View File

@ -1,6 +1,6 @@
#
#
# This is a placeholder file. It does nothing and is not used.
#
#
# If you are seeing this file as your linker script (named
# libstdc++-symbols.ver), then either 1) the configuration process
# determined that symbol versioning should not be done, or 2) you

View File

@ -33,7 +33,7 @@
#ifdef __cplusplus
namespace __cxxabiv1
{
extern "C"
extern "C"
{
#endif
@ -49,7 +49,7 @@ namespace __cxxabiv1
// We also want the element size in array cookies.
#define _GLIBCXX_ELTSIZE_IN_COOKIE 1
// __cxa_vec_ctor should return a pointer to the array.
typedef void * __cxa_vec_ctor_return_type;
#define _GLIBCXX_CXA_VEC_CTOR_RETURN(x) return x
@ -79,4 +79,4 @@ namespace __cxxabiv1
} // namespace __cxxabiv1
#endif
#endif
#endif

View File

@ -28,4 +28,4 @@
// This entity must not cross a page boundary.
typedef int _Atomic_word __attribute__ ((__aligned__ (4)));
#endif
#endif

View File

@ -37,4 +37,4 @@ typedef int _Atomic_word;
// This is a memory order release fence.
#define _GLIBCXX_WRITE_MEM_BARRIER __atomic_thread_fence (__ATOMIC_RELEASE)
#endif
#endif

View File

@ -30,7 +30,7 @@ namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
_Atomic_word
_Atomic_word
__attribute__ ((__unused__))
__exchange_and_add(volatile _Atomic_word* __mem, int __val) throw ()
{ return __atomic_fetch_add(__mem, __val, __ATOMIC_ACQ_REL); }

View File

@ -25,7 +25,7 @@
#include <ext/atomicity.h>
#include <ext/concurrence.h>
namespace
namespace
{
__gnu_cxx::__mutex&
get_atomic_mutex()

View File

@ -33,7 +33,7 @@
#ifdef __cplusplus
namespace __cxxabiv1
{
extern "C"
extern "C"
{
#endif
@ -56,4 +56,4 @@ namespace __cxxabiv1
} // namespace __cxxabiv1
#endif
#endif
#endif

View File

@ -34,7 +34,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{
static volatile int _S_atomicity_lock;
};
template<int _Inst>
volatile int
_Atomicity_lock<_Inst>::_S_atomicity_lock __attribute__ ((aligned (16))) = 1;
@ -50,7 +50,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_Atomic_word result;
int tmp;
volatile int& lock = _Atomicity_lock<0>::_S_atomicity_lock;
__asm__ __volatile__ ("ldcw 0(%1),%0\n\t"
"cmpib,<>,n 0,%0,.+20\n\t"
"ldw 0(%1),%0\n\t"
@ -60,21 +60,21 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: "=&r" (tmp)
: "r" (&lock)
: "memory");
result = *__mem;
*__mem = result + __val;
__asm__ __volatile__ ("stw %1,0(%0)"
: : "r" (&lock), "r" (tmp) : "memory");
return result;
}
void
__attribute__ ((__unused__))
__atomic_add(volatile _Atomic_word* __mem, int __val) throw ()
{
int tmp;
volatile int& lock = _Atomicity_lock<0>::_S_atomicity_lock;
__asm__ __volatile__ ("ldcw 0(%1),%0\n\t"
"cmpib,<>,n 0,%0,.+20\n\t"
"ldw 0(%1),%0\n\t"
@ -84,7 +84,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: "=&r" (tmp)
: "r" (&lock)
: "memory");
*__mem += __val;
__asm__ __volatile__ ("stw %1,0(%0)"
: : "r" (&lock), "r" (tmp) : "memory");

View File

@ -38,32 +38,32 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
volatile _Atomic_word _Atomicity_lock<__inst>::_S_atomicity_lock = 0;
template volatile _Atomic_word _Atomicity_lock<0>::_S_atomicity_lock;
_Atomic_word
_Atomic_word
__attribute__ ((__unused__))
__exchange_and_add(volatile _Atomic_word* __mem, int __val) throw ()
{
register _Atomic_word __result, __tmp = 1;
// Obtain the atomic exchange/add spin lock.
do
do
{
__asm__ __volatile__ ("xchg{l} {%0,%1|%1,%0}"
: "=m" (_Atomicity_lock<0>::_S_atomicity_lock),
"+r" (__tmp)
: "m" (_Atomicity_lock<0>::_S_atomicity_lock));
}
}
while (__tmp);
__result = *__mem;
*__mem += __val;
// Release spin lock.
_Atomicity_lock<0>::_S_atomicity_lock = 0;
return __result;
}
void
__attribute__ ((__unused__))
__atomic_add(volatile _Atomic_word* __mem, int __val) throw ()

View File

@ -28,17 +28,17 @@ namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
_Atomic_word
_Atomic_word
__attribute__ ((__unused__))
__exchange_and_add(volatile _Atomic_word* __mem, int __val) throw ()
{
register _Atomic_word __result;
__asm__ __volatile__ ("lock; xadd{l} {%0,%1|%1,%0}"
: "=r" (__result), "=m" (*__mem)
: "=r" (__result), "=m" (*__mem)
: "0" (__val), "m" (*__mem));
return __result;
}
void
__attribute__ ((__unused__))
__atomic_add(volatile _Atomic_word* __mem, int __val) throw ()

View File

@ -170,7 +170,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
}
while (__v2 > __maskval || __v2 < __tmp);
__v.__i = _mm_set_epi64x(__v1, __v2);
}

View File

@ -32,7 +32,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|| defined(__mc68040__) || defined(__mc68060__) ) \
&& !defined(__mcpu32__)
// These variants support compare-and-swap.
_Atomic_word
_Atomic_word
__attribute__ ((__unused__))
__exchange_and_add(volatile _Atomic_word* __mem, int __val) throw ()
{
@ -58,16 +58,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
short __level, __tmpsr;
__asm__ __volatile__ ("move%.w %%sr,%0\n\tor%.l %0,%1\n\tmove%.w %1,%%sr"
: "=d"(__level), "=d"(__tmpsr) : "1"(0x700));
__result = *__mem;
*__mem = __result + __val;
*__mem = __result + __val;
__asm__ __volatile__ ("move%.w %0,%%sr" : : "d"(__level));
return __result;
}
#else
template<int __inst>
struct _Atomicity_lock
{
@ -76,29 +76,29 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<int __inst>
volatile unsigned char _Atomicity_lock<__inst>::_S_atomicity_lock = 0;
template volatile unsigned char _Atomicity_lock<0>::_S_atomicity_lock;
_Atomic_word
_Atomic_word
__attribute__ ((__unused__))
__exchange_and_add(volatile _Atomic_word* __mem, int __val) throw ()
{
_Atomic_word __result;
// bset with no immediate addressing (not SMP-safe)
#if defined(__mcfisaa__) || defined(__mcfisaaplus__)
__asm__ __volatile__("1: bset.b #7,%0@\n\tjbne 1b"
: /* no outputs */
: "a"(&_Atomicity_lock<0>::_S_atomicity_lock)
: "cc", "memory");
// CPU32 and CF ISAs B & C support test-and-set (SMP-safe).
#elif defined(__mcpu32__) || defined(__mcfisab__) || defined (__mcfisac__)
__asm__ __volatile__("1: tas %0\n\tjbne 1b"
: "+m"(_Atomicity_lock<0>::_S_atomicity_lock)
: /* none */
: "cc");
// Use bset with immediate addressing for 68000/68010 (not SMP-safe)
// NOTE: TAS is available on the 68000, but unsupported by some Amiga
// memory controllers.
@ -108,15 +108,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: /* none */
: "cc");
#endif
__result = *__mem;
*__mem = __result + __val;
_Atomicity_lock<0>::_S_atomicity_lock = 0;
return __result;
}
#endif /* TAS / BSET */
void

View File

@ -45,4 +45,4 @@
#endif
#endif
#endif

View File

@ -46,14 +46,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: "r" (__mem), "r" (__val_extended), "m" (*__mem));
return __tmp2;
}
void
__attribute__ ((__unused__))
__atomic_add(volatile _Atomic_word* __mem, int __val) throw ()
{
_Atomic_word __tmp1, __tmp2;
_Atomic_word __val_extended = __val;
__asm__ __volatile__("1: ldx [%3], %0\n\t"
" add %0, %4, %1\n\t"
" casx [%3], %0, %1\n\t"
@ -63,7 +63,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: "=&r" (__tmp1), "=&r" (__tmp2), "=m" (*__mem)
: "r" (__mem), "r" (__val_extended), "m" (*__mem));
}
#else /* __arch32__ */
template<int __inst>
@ -74,15 +74,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<int __inst>
unsigned char _Atomicity_lock<__inst>::_S_atomicity_lock = 0;
template unsigned char _Atomicity_lock<0>::_S_atomicity_lock;
_Atomic_word
__attribute__ ((__unused__))
__exchange_and_add(volatile _Atomic_word* __mem, int __val) throw ()
{
_Atomic_word __result, __tmp;
__asm__ __volatile__("1: ldstub [%1], %0\n\t"
" cmp %0, 0\n\t"
" bne 1b\n\t"
@ -98,13 +98,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: "memory");
return __result;
}
void
__attribute__ ((__unused__))
__atomic_add(volatile _Atomic_word* __mem, int __val) throw ()
{
_Atomic_word __tmp;
__asm__ __volatile__("1: ldstub [%1], %0\n\t"
" cmp %0, 0\n\t"
" bne 1b\n\t"
@ -117,7 +117,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: /* no outputs */
: "r" (&_Atomicity_lock<0>::_S_atomicity_lock)
: "memory");
}
}
#endif /* __arch32__ */
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -41,7 +41,7 @@
// Pick up FIONREAD on Solaris 2
#ifdef _GLIBCXX_HAVE_SYS_IOCTL_H
#define BSD_COMP
#define BSD_COMP
#include <sys/ioctl.h>
#endif
@ -65,14 +65,14 @@
#include <limits> // For <off_t>::max() and min() and <streamsize>::max()
namespace
namespace
{
// Map ios_base::openmode flags to a string for use in fopen().
// Table of valid combinations as given in [lib.filebuf.members]/2.
static const char*
fopen_mode(std::ios_base::openmode mode)
{
enum
enum
{
in = std::ios_base::in,
out = std::ios_base::out,
@ -167,7 +167,7 @@ namespace
__nleft -= xwrite(__fd, __s2 + __off, __n2 - __off);
break;
}
__s1 += __ret;
__n1_left -= __ret;
}
@ -188,15 +188,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__basic_file<char>::~__basic_file()
{ this->close(); }
__basic_file<char>*
__basic_file<char>::sys_open(__c_file* __file, ios_base::openmode)
__basic_file<char>::sys_open(__c_file* __file, ios_base::openmode)
{
__basic_file* __ret = NULL;
if (!this->is_open() && __file)
{
int __err;
errno = 0;
errno = 0;
do
__err = this->sync();
while (__err && errno == EINTR);
@ -209,7 +209,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __ret;
}
__basic_file<char>*
__basic_file<char>::sys_open(int __fd, ios_base::openmode __mode) throw ()
{
@ -225,9 +225,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __ret;
}
__basic_file<char>*
__basic_file<char>::open(const char* __name, ios_base::openmode __mode,
__basic_file<char>*
__basic_file<char>::open(const char* __name, ios_base::openmode __mode,
int /*__prot*/)
{
__basic_file* __ret = NULL;
@ -246,22 +246,22 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __ret;
}
bool
bool
__basic_file<char>::is_open() const throw ()
{ return _M_cfile != 0; }
int
int
__basic_file<char>::fd() throw ()
{ return fileno(_M_cfile); }
__c_file*
__basic_file<char>::file() throw ()
{ return _M_cfile; }
__basic_file<char>*
__basic_file<char>*
__basic_file<char>::close()
{
{
__basic_file* __ret = static_cast<__basic_file*>(NULL);
if (this->is_open())
{
@ -283,8 +283,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __ret;
}
streamsize
streamsize
__basic_file<char>::xsgetn(char* __s, streamsize __n)
{
streamsize __ret;
@ -294,11 +294,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
return __ret;
}
streamsize
streamsize
__basic_file<char>::xsputn(const char* __s, streamsize __n)
{ return xwrite(this->fd(), __s, __n); }
streamsize
streamsize
__basic_file<char>::xsputn_2(const char* __s1, streamsize __n1,
const char* __s2, streamsize __n2)
{
@ -328,8 +328,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#endif
}
int
__basic_file<char>::sync()
int
__basic_file<char>::sync()
{ return fflush(_M_cfile); }
streamsize
@ -337,11 +337,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{
#ifndef _GLIBCXX_NO_IOCTL
#ifdef FIONREAD
// Pipes and sockets.
// Pipes and sockets.
int __num = 0;
int __r = ioctl(this->fd(), FIONREAD, &__num);
if (!__r && __num >= 0)
return __num;
return __num;
#endif
#endif
@ -352,7 +352,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__pfd[0].events = POLLIN;
if (poll(__pfd, 1, 0) <= 0)
return 0;
#endif
#endif
#if defined(_GLIBCXX_HAVE_S_ISREG) || defined(_GLIBCXX_HAVE_S_IFREG)
// Regular files.

View File

@ -47,7 +47,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// Generic declaration.
template<typename _CharT>
class __basic_file;
class __basic_file;
// Specialization.
template<>
@ -81,7 +81,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
#endif
__basic_file*
__basic_file*
open(const char* __name, ios_base::openmode __mode, int __prot = 0664);
__basic_file*
@ -90,13 +90,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__basic_file*
sys_open(int __fd, ios_base::openmode __mode) throw ();
__basic_file*
close();
__basic_file*
close();
_GLIBCXX_PURE bool
_GLIBCXX_PURE bool
is_open() const throw ();
_GLIBCXX_PURE int
_GLIBCXX_PURE int
fd() throw ();
_GLIBCXX_PURE __c_file*
@ -104,20 +104,20 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
~__basic_file();
streamsize
streamsize
xsputn(const char* __s, streamsize __n);
streamsize
streamsize
xsputn_2(const char* __s1, streamsize __n1,
const char* __s2, streamsize __n2);
streamsize
streamsize
xsgetn(char* __s, streamsize __n);
streamoff
seekoff(streamoff __off, ios_base::seekdir __way) throw ();
int
int
sync();
streamsize
@ -127,4 +127,4 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_GLIBCXX_END_NAMESPACE_VERSION
} // namespace
#endif
#endif

View File

@ -40,19 +40,19 @@ namespace std _GLIBCXX_VISIBILITY(default)
// various /config/os/* files.
ctype_byname<char>::ctype_byname(const char* __s, size_t __refs)
: ctype<char>(0, false, __refs)
{
: ctype<char>(0, false, __refs)
{
if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0)
{
this->_S_destroy_c_locale(this->_M_c_locale_ctype);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
}
}
ctype_byname<char>::~ctype_byname()
{ }
#ifdef _GLIBCXX_USE_WCHAR_T
#ifdef _GLIBCXX_USE_WCHAR_T
ctype<wchar_t>::__wmask_type
ctype<wchar_t>::_M_convert_to_wmask(const mask __m) const throw()
{
@ -60,7 +60,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
// never gets called.
return __m;
};
wchar_t
ctype<wchar_t>::do_toupper(wchar_t __c) const
{ return towupper(__c); }
@ -75,11 +75,11 @@ namespace std _GLIBCXX_VISIBILITY(default)
}
return __hi;
}
wchar_t
ctype<wchar_t>::do_tolower(wchar_t __c) const
{ return towlower(__c); }
const wchar_t*
ctype<wchar_t>::do_tolower(wchar_t* __lo, const wchar_t* __hi) const
{
@ -96,7 +96,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
do_widen(char __c) const
{ return _M_widen[static_cast<unsigned char>(__c)]; }
const char*
const char*
ctype<wchar_t>::
do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const
{
@ -112,16 +112,16 @@ namespace std _GLIBCXX_VISIBILITY(default)
char
ctype<wchar_t>::
do_narrow(wchar_t __wc, char __dfault) const
{
{
if (__wc >= 0 && __wc < 128 && _M_narrow_ok)
return _M_narrow[__wc];
const int __c = wctob(__wc);
return (__c == EOF ? __dfault : static_cast<char>(__c));
return (__c == EOF ? __dfault : static_cast<char>(__c));
}
const wchar_t*
ctype<wchar_t>::
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
char* __dest) const
{
if (_M_narrow_ok)

View File

@ -42,7 +42,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#ifdef _GLIBCXX_USE_WCHAR_T
codecvt_base::result
codecvt<wchar_t, char, mbstate_t>::
do_out(state_type& __state, const intern_type* __from,
do_out(state_type& __state, const intern_type* __from,
const intern_type* __from_end, const intern_type*& __from_next,
extern_type* __to, extern_type* __to_end,
extern_type*& __to_next) const
@ -108,12 +108,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
uselocale((locale_t)__old);
return __ret;
return __ret;
}
codecvt_base::result
codecvt<wchar_t, char, mbstate_t>::
do_in(state_type& __state, const extern_type* __from,
do_in(state_type& __state, const extern_type* __from,
const extern_type* __from_end, const extern_type*& __from_next,
intern_type* __to, intern_type* __to_end,
intern_type*& __to_next) const
@ -155,12 +155,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
break;
}
__from_next = __from;
__state = __tmp_state;
__state = __tmp_state;
__ret = error;
}
else if (__from_next && __from_next < __from_chunk_end)
{
// It is unclear what to return in this case (see DR 382).
// It is unclear what to return in this case (see DR 382).
__to_next += __conv;
__ret = partial;
}
@ -175,7 +175,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
if (__to_next < __to_end)
{
// XXX Probably wrong for stateful encodings
__tmp_state = __state;
__tmp_state = __state;
++__from_next;
*__to_next++ = L'\0';
}
@ -186,10 +186,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
uselocale((locale_t)__old);
return __ret;
return __ret;
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_encoding() const throw()
{
@ -201,9 +201,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__ret = 1;
uselocale((locale_t)__old);
return __ret;
}
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_max_length() const throw()
{
@ -213,8 +213,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
uselocale((locale_t)__old);
return __ret;
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_length(state_type& __state, const extern_type* __from,
const extern_type* __end, size_t __max) const
@ -227,10 +227,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// mbsnrtowcs is *very* fast but stops if encounters NUL characters:
// in case we advance past it and then continue, in a loop.
// NB: mbsnrtowcs is a GNU extension
// A dummy internal buffer is needed in order for mbsnrtocws to consider
// its fourth parameter (it wouldn't with NULL as first parameter).
wchar_t* __to = static_cast<wchar_t*>(__builtin_alloca(sizeof(wchar_t)
wchar_t* __to = static_cast<wchar_t*>(__builtin_alloca(sizeof(wchar_t)
* __max));
while (__from < __end && __max)
{
@ -264,7 +264,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
if (!__from)
__from = __from_chunk_end;
__ret += __from - __tmp_from;
__max -= __conv;
@ -280,7 +280,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
uselocale((locale_t)__old);
return __ret;
return __ret;
}
#endif

View File

@ -39,30 +39,30 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// These are basically extensions to char_traits, and perhaps should
// be put there instead of here.
template<>
int
collate<char>::_M_compare(const char* __one,
int
collate<char>::_M_compare(const char* __one,
const char* __two) const throw()
{
{
int __cmp = strcoll_l(__one, __two, (locale_t)_M_c_locale_collate);
return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0);
}
template<>
size_t
collate<char>::_M_transform(char* __to, const char* __from,
collate<char>::_M_transform(char* __to, const char* __from,
size_t __n) const throw()
{ return strxfrm_l(__to, __from, __n, (locale_t)_M_c_locale_collate); }
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
int
collate<wchar_t>::_M_compare(const wchar_t* __one,
int
collate<wchar_t>::_M_compare(const wchar_t* __one,
const wchar_t* __two) const throw()
{
int __cmp = wcscoll_l(__one, __two, (locale_t)_M_c_locale_collate);
return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0);
}
template<>
size_t
collate<wchar_t>::_M_transform(wchar_t* __to, const wchar_t* __from,

View File

@ -44,19 +44,19 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: The other ctype<char> specializations are in src/locale.cc and
// various /config/os/* files.
ctype_byname<char>::ctype_byname(const char* __s, size_t __refs)
: ctype<char>(0, false, __refs)
{
: ctype<char>(0, false, __refs)
{
if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0)
{
this->_S_destroy_c_locale(this->_M_c_locale_ctype);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
}
}
ctype_byname<char>::~ctype_byname()
{ }
#ifdef _GLIBCXX_USE_WCHAR_T
#ifdef _GLIBCXX_USE_WCHAR_T
ctype<wchar_t>::__wmask_type
ctype<wchar_t>::_M_convert_to_wmask(const mask __m) const throw()
{
@ -104,7 +104,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __ret;
}
wchar_t
ctype<wchar_t>::do_toupper(wchar_t __c) const
{ return towupper_l(__c, (locale_t)_M_c_locale_ctype); }
@ -119,11 +119,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __hi;
}
wchar_t
ctype<wchar_t>::do_tolower(wchar_t __c) const
{ return towlower_l(__c, (locale_t)_M_c_locale_ctype); }
const wchar_t*
ctype<wchar_t>::do_tolower(wchar_t* __lo, const wchar_t* __hi) const
{
@ -140,7 +140,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
do_widen(char __c) const
{ return _M_widen[static_cast<unsigned char>(__c)]; }
const char*
const char*
ctype<wchar_t>::
do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const
{
@ -162,12 +162,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__c_locale __old = (__c_locale)uselocale((locale_t)_M_c_locale_ctype);
const int __c = wctob(__wc);
uselocale((locale_t)__old);
return (__c == EOF ? __dfault : static_cast<char>(__c));
return (__c == EOF ? __dfault : static_cast<char>(__c));
}
const wchar_t*
ctype<wchar_t>::
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
char* __dest) const
{
__c_locale __old = (__c_locale)uselocale((locale_t)_M_c_locale_ctype);

View File

@ -44,9 +44,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// Construct and return valid pattern consisting of some combination of:
// space none symbol sign value
money_base::pattern
money_base::_S_construct_pattern(char __precedes, char __space,
money_base::_S_construct_pattern(char __precedes, char __space,
char __posn) throw()
{
{
pattern __ret;
// This insanely complicated routine attempts to construct a valid
@ -54,7 +54,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// if (__precedes) symbol -> value
// else value -> symbol
// if (__space) space
// else none
@ -139,7 +139,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
if (__precedes)
{
__ret.field[0] = sign;
__ret.field[1] = symbol;
__ret.field[1] = symbol;
if (__space)
{
__ret.field[2] = space;
@ -147,7 +147,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
{
__ret.field[2] = value;
__ret.field[2] = value;
__ret.field[3] = none;
}
}
@ -211,7 +211,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
moneypunct<char, true>::_M_initialize_moneypunct(__c_locale __cloc,
moneypunct<char, true>::_M_initialize_moneypunct(__c_locale __cloc,
const char*)
{
if (!_M_data)
@ -270,7 +270,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__try
{
size_t __len;
// Check for NULL, which implies no grouping.
if (lc->mon_thousands_sep == NULL ||
lc->mon_thousands_sep[0] == '\0')
@ -365,7 +365,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
moneypunct<char, false>::_M_initialize_moneypunct(__c_locale __cloc,
moneypunct<char, false>::_M_initialize_moneypunct(__c_locale __cloc,
const char*)
{
if (!_M_data)
@ -550,7 +550,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
void
moneypunct<wchar_t, true>::_M_initialize_moneypunct(__c_locale __cloc,
moneypunct<wchar_t, true>::_M_initialize_moneypunct(__c_locale __cloc,
const char*)
{
if (!_M_data)
@ -652,9 +652,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_positive_sign = L"";
_M_data->_M_positive_sign_size =
_M_data->_M_positive_sign_size =
wcslen(_M_data->_M_positive_sign);
__len = strlen(__cnegsign);
if (!__nposn)
_M_data->_M_negative_sign = L"()";
@ -667,9 +667,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_negative_sign = L"";
_M_data->_M_negative_sign_size =
_M_data->_M_negative_sign_size =
wcslen(_M_data->_M_negative_sign);
// _Intl == true.
__len = strlen(__ccurr);
if (__len)
@ -689,11 +689,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data = 0;
delete [] __group;
delete [] __wcs_ps;
delete [] __wcs_ns;
delete [] __wcs_ns;
uselocale((locale_t)__old);
__throw_exception_again;
}
}
char __pprecedes = lc->int_p_cs_precedes;
char __pspace = lc->int_p_sep_by_space;
char __pposn = lc->int_p_sign_posn;
@ -812,7 +812,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_positive_sign = L"";
_M_data->_M_positive_sign_size =
_M_data->_M_positive_sign_size =
wcslen(_M_data->_M_positive_sign);
__len = strlen(__cnegsign);
@ -827,7 +827,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_negative_sign = L"";
_M_data->_M_negative_sign_size =
_M_data->_M_negative_sign_size =
wcslen(_M_data->_M_negative_sign);
// _Intl == true.
@ -849,7 +849,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data = 0;
delete [] __group;
delete [] __wcs_ps;
delete [] __wcs_ns;
delete [] __wcs_ns;
uselocale((locale_t)__old);
__throw_exception_again;
}

View File

@ -37,7 +37,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
template<>
void
numpunct<char>::_M_initialize_numpunct(__c_locale __cloc)
{
@ -123,17 +123,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_falsename = "false";
_M_data->_M_falsename_size = 5;
}
template<>
template<>
numpunct<char>::~numpunct()
{
if (_M_data->_M_grouping_size)
delete [] _M_data->_M_grouping;
delete _M_data;
}
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
template<>
void
numpunct<wchar_t>::_M_initialize_numpunct(__c_locale __cloc)
{
@ -222,7 +222,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_falsename_size = 5;
}
template<>
template<>
numpunct<wchar_t>::~numpunct()
{
if (_M_data->_M_grouping_size)

View File

@ -44,7 +44,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
__timepunct<char>::
_M_put(char* __s, size_t __maxlen, const char* __format,
_M_put(char* __s, size_t __maxlen, const char* __format,
const tm* __tm) const throw()
{
const size_t __len = strftime_l(__s, __maxlen, __format, __tm,
@ -54,7 +54,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__s[0] = '\0';
}
template<>
template<>
void
__timepunct<char>::_M_initialize_timepunct(__c_locale __cloc)
{
@ -124,7 +124,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
{
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
_M_data->_M_date_format = nl_langinfo_l(D_FMT, (locale_t)__cloc);
_M_data->_M_date_era_format = nl_langinfo_l(ERA_D_FMT,
@ -193,7 +193,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
__timepunct<wchar_t>::
_M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format,
_M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format,
const tm* __tm) const throw()
{
const size_t __len = wcsftime_l(__s, __maxlen, __format, __tm,
@ -211,7 +211,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
langstring[fmtlen] = L'\0'; \
_M_data->M = langstring;
template<>
template<>
void
__timepunct<wchar_t>::_M_initialize_timepunct(__c_locale __cloc)
{
@ -285,7 +285,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
wchar_t holder[128];
size_t fmtlen;
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
WIDE_LANGINFO(_M_date_format, D_FMT)
WIDE_LANGINFO(_M_date_era_format, ERA_D_FMT)
@ -345,7 +345,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
}
template<>
template<>
__timepunct<wchar_t>::~__timepunct()
{
delete [] _M_data->_M_date_format;

View File

@ -40,21 +40,21 @@ namespace std _GLIBCXX_VISIBILITY(default)
_GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _CharT>
__timepunct<_CharT>::__timepunct(size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
__timepunct<_CharT>::__timepunct(size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
_M_name_timepunct(_S_get_c_name())
{ _M_initialize_timepunct(); }
template<typename _CharT>
__timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs)
: facet(__refs), _M_data(__cache), _M_c_locale_timepunct(0),
__timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs)
: facet(__refs), _M_data(__cache), _M_c_locale_timepunct(0),
_M_name_timepunct(_S_get_c_name())
{ _M_initialize_timepunct(); }
template<typename _CharT>
__timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s,
size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
_M_name_timepunct(0)
{
if (__builtin_strcmp(__s, _S_get_c_name()) != 0)
@ -79,11 +79,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _CharT>
__timepunct<_CharT>::~__timepunct()
{
{
if (_M_name_timepunct != _S_get_c_name())
delete [] _M_name_timepunct;
delete _M_data;
_S_destroy_c_locale(_M_c_locale_timepunct);
delete _M_data;
_S_destroy_c_locale(_M_c_locale_timepunct);
}
// specialization

View File

@ -53,7 +53,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// fall back to the unsafe vsprintf which, in general, can be dangerous
// and should be avoided.
inline int
__convert_from_v(const __c_locale&, char* __out,
__convert_from_v(const __c_locale&, char* __out,
const int __size __attribute__((__unused__)),
const char* __fmt, ...)
{

View File

@ -41,7 +41,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#ifdef _GLIBCXX_USE_WCHAR_T
codecvt_base::result
codecvt<wchar_t, char, mbstate_t>::
do_out(state_type& __state, const intern_type* __from,
do_out(state_type& __state, const intern_type* __from,
const intern_type* __from_end, const intern_type*& __from_next,
extern_type* __to, extern_type* __to_end,
extern_type*& __to_next) const
@ -88,7 +88,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__ret = partial;
break;
}
memcpy(__to, __buf, __conv);
__state = __tmp_state;
__to += __conv;
@ -101,12 +101,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__from_next = __from;
__to_next = __to;
return __ret;
return __ret;
}
codecvt_base::result
codecvt<wchar_t, char, mbstate_t>::
do_in(state_type& __state, const extern_type* __from,
do_in(state_type& __state, const extern_type* __from,
const extern_type* __from_end, const extern_type*& __from_next,
intern_type* __to, intern_type* __to_end,
intern_type*& __to_next) const
@ -153,10 +153,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__from_next = __from;
__to_next = __to;
return __ret;
return __ret;
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_encoding() const throw()
{
@ -166,9 +166,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
if (MB_CUR_MAX == 1)
__ret = 1;
return __ret;
}
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_max_length() const throw()
{
@ -176,8 +176,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
int __ret = MB_CUR_MAX;
return __ret;
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_length(state_type& __state, const extern_type* __from,
const extern_type* __end, size_t __max) const
@ -211,7 +211,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__max--;
}
return __ret;
return __ret;
}
#endif

View File

@ -38,30 +38,30 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// These are basically extensions to char_traits, and perhaps should
// be put there instead of here.
template<>
int
collate<char>::_M_compare(const char* __one,
int
collate<char>::_M_compare(const char* __one,
const char* __two) const throw()
{
{
int __cmp = strcoll(__one, __two);
return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0);
}
template<>
size_t
collate<char>::_M_transform(char* __to, const char* __from,
collate<char>::_M_transform(char* __to, const char* __from,
size_t __n) const throw()
{ return strxfrm(__to, __from, __n); }
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
int
collate<wchar_t>::_M_compare(const wchar_t* __one,
int
collate<wchar_t>::_M_compare(const wchar_t* __one,
const wchar_t* __two) const throw()
{
int __cmp = wcscoll(__one, __two);
return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0);
}
template<>
size_t
collate<wchar_t>::_M_transform(wchar_t* __to, const wchar_t* __from,

View File

@ -40,19 +40,19 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: The other ctype<char> specializations are in src/locale.cc and
// various /config/os/* files.
ctype_byname<char>::ctype_byname(const char* __s, size_t __refs)
: ctype<char>(0, false, __refs)
{
: ctype<char>(0, false, __refs)
{
if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0)
{
this->_S_destroy_c_locale(this->_M_c_locale_ctype);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
}
}
ctype_byname<char>::~ctype_byname()
{ }
#ifdef _GLIBCXX_USE_WCHAR_T
#ifdef _GLIBCXX_USE_WCHAR_T
ctype<wchar_t>::__wmask_type
ctype<wchar_t>::_M_convert_to_wmask(const mask __m) const throw()
{
@ -102,7 +102,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __ret;
};
wchar_t
ctype<wchar_t>::do_toupper(wchar_t __c) const
{ return towupper(__c); }
@ -117,11 +117,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __hi;
}
wchar_t
ctype<wchar_t>::do_tolower(wchar_t __c) const
{ return towlower(__c); }
const wchar_t*
ctype<wchar_t>::do_tolower(wchar_t* __lo, const wchar_t* __hi) const
{
@ -136,11 +136,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
bool
ctype<wchar_t>::
do_is(mask __m, char_type __c) const
{
{
bool __ret = false;
// Generically, 15 (instead of 11) since we don't know the numerical
// encoding of the various categories in /usr/include/ctype.h.
const size_t __bitmasksize = 15;
const size_t __bitmasksize = 15;
for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur)
if (__m & _M_bit[__bitcur]
&& iswctype(__c, _M_wmask[__bitcur]))
@ -148,10 +148,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__ret = true;
break;
}
return __ret;
return __ret;
}
const wchar_t*
const wchar_t*
ctype<wchar_t>::
do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const
{
@ -159,7 +159,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{
// Generically, 15 (instead of 11) since we don't know the numerical
// encoding of the various categories in /usr/include/ctype.h.
const size_t __bitmasksize = 15;
const size_t __bitmasksize = 15;
mask __m = 0;
for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur)
if (iswctype(*__lo, _M_wmask[__bitcur]))
@ -168,8 +168,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __hi;
}
const wchar_t*
const wchar_t*
ctype<wchar_t>::
do_scan_is(mask __m, const wchar_t* __lo, const wchar_t* __hi) const
{
@ -191,8 +191,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<wchar_t>::
do_widen(char __c) const
{ return _M_widen[static_cast<unsigned char>(__c)]; }
const char*
const char*
ctype<wchar_t>::
do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const
{
@ -208,16 +208,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
char
ctype<wchar_t>::
do_narrow(wchar_t __wc, char __dfault) const
{
{
if (__wc >= 0 && __wc < 128 && _M_narrow_ok)
return _M_narrow[__wc];
const int __c = wctob(__wc);
return (__c == EOF ? __dfault : static_cast<char>(__c));
return (__c == EOF ? __dfault : static_cast<char>(__c));
}
const wchar_t*
ctype<wchar_t>::
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
char* __dest) const
{
if (_M_narrow_ok)
@ -265,10 +265,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_widen[__i] = btowc(__i);
for (size_t __i = 0; __i <= 15; ++__i)
{
{
_M_bit[__i] = static_cast<mask>(1 << __i);
_M_wmask[__i] = _M_convert_to_wmask(_M_bit[__i]);
}
}
}
#endif // _GLIBCXX_USE_WCHAR_T

View File

@ -44,13 +44,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{ _M_c_locale_messages = _S_get_c_locale(); }
template<typename _CharT>
messages<_CharT>::messages(__c_locale, const char*, size_t __refs)
messages<_CharT>::messages(__c_locale, const char*, size_t __refs)
: facet(__refs)
{ _M_c_locale_messages = _S_get_c_locale(); }
template<typename _CharT>
typename messages<_CharT>::catalog
messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc,
typename messages<_CharT>::catalog
messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc,
const char*) const
{ return this->do_open(__s, __loc); }
@ -60,31 +60,31 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{ _S_destroy_c_locale(_M_c_locale_messages); }
template<typename _CharT>
typename messages<_CharT>::catalog
typename messages<_CharT>::catalog
messages<_CharT>::do_open(const basic_string<char>&, const locale&) const
{ return 0; }
template<typename _CharT>
typename messages<_CharT>::string_type
messages<_CharT>::do_get(catalog, int, int,
typename messages<_CharT>::string_type
messages<_CharT>::do_get(catalog, int, int,
const string_type& __dfault) const
{ return __dfault; }
template<typename _CharT>
void
messages<_CharT>::do_close(catalog) const
void
messages<_CharT>::do_close(catalog) const
{ }
// messages_byname
template<typename _CharT>
messages_byname<_CharT>::messages_byname(const char* __s, size_t __refs)
: messages<_CharT>(__refs)
{
: messages<_CharT>(__refs)
{
if (__builtin_strcmp(__s, "C") != 0
&& __builtin_strcmp(__s, "POSIX") != 0)
{
this->_S_destroy_c_locale(this->_M_c_locale_messages);
this->_S_create_c_locale(this->_M_c_locale_messages, __s);
this->_S_create_c_locale(this->_M_c_locale_messages, __s);
}
}

View File

@ -34,7 +34,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
template<>
void
numpunct<char>::_M_initialize_numpunct(__c_locale)
{
@ -48,10 +48,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_decimal_point = '.';
_M_data->_M_thousands_sep = ',';
for (size_t __i = 0; __i < __num_base::_S_oend; ++__i)
_M_data->_M_atoms_out[__i] = __num_base::_S_atoms_out[__i];
for (size_t __i = 0; __i < __num_base::_S_iend; ++__i)
_M_data->_M_atoms_in[__i] = __num_base::_S_atoms_in[__i];
@ -61,12 +61,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_falsename_size = 5;
}
template<>
template<>
numpunct<char>::~numpunct()
{ delete _M_data; }
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
template<>
void
numpunct<wchar_t>::_M_initialize_numpunct(__c_locale)
{
@ -77,15 +77,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_grouping = "";
_M_data->_M_grouping_size = 0;
_M_data->_M_use_grouping = false;
_M_data->_M_decimal_point = L'.';
_M_data->_M_thousands_sep = L',';
// Use ctype::widen code without the facet...
for (size_t __i = 0; __i < __num_base::_S_oend; ++__i)
_M_data->_M_atoms_out[__i] =
static_cast<wchar_t>(__num_base::_S_atoms_out[__i]);
for (size_t __i = 0; __i < __num_base::_S_iend; ++__i)
_M_data->_M_atoms_in[__i] =
static_cast<wchar_t>(__num_base::_S_atoms_in[__i]);
@ -96,7 +96,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_falsename_size = 5;
}
template<>
template<>
numpunct<wchar_t>::~numpunct()
{ delete _M_data; }
#endif

View File

@ -39,24 +39,24 @@ namespace std _GLIBCXX_VISIBILITY(default)
_GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _CharT>
__timepunct<_CharT>::__timepunct(size_t __refs)
__timepunct<_CharT>::__timepunct(size_t __refs)
: facet(__refs), _M_data(0)
{
{
_M_name_timepunct = _S_get_c_name();
_M_initialize_timepunct();
_M_initialize_timepunct();
}
template<typename _CharT>
__timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs)
__timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs)
: facet(__refs), _M_data(__cache)
{
{
_M_name_timepunct = _S_get_c_name();
_M_initialize_timepunct();
_M_initialize_timepunct();
}
template<typename _CharT>
__timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s,
size_t __refs)
__timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s,
size_t __refs)
: facet(__refs), _M_data(0)
{
if (__builtin_strcmp(__s, _S_get_c_name()) != 0)
@ -81,11 +81,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _CharT>
__timepunct<_CharT>::~__timepunct()
{
{
if (_M_name_timepunct != _S_get_c_name())
delete [] _M_name_timepunct;
delete _M_data;
_S_destroy_c_locale(_M_c_locale_timepunct);
_S_destroy_c_locale(_M_c_locale_timepunct);
}
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -63,7 +63,7 @@ extern "C" __typeof(wcscoll_l) __wcscoll_l;
extern "C" __typeof(wcsftime_l) __wcsftime_l;
extern "C" __typeof(wcsxfrm_l) __wcsxfrm_l;
extern "C" __typeof(wctype_l) __wctype_l;
#endif
#endif
#endif // GLIBC 2.3 and later

View File

@ -43,7 +43,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
__convert_to_v(const char* __s, float& __v, ios_base::iostate& __err,
__convert_to_v(const char* __s, float& __v, ios_base::iostate& __err,
const __c_locale& __cloc) throw()
{
char* __sanity;
@ -70,7 +70,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
__convert_to_v(const char* __s, double& __v, ios_base::iostate& __err,
__convert_to_v(const char* __s, double& __v, ios_base::iostate& __err,
const __c_locale& __cloc) throw()
{
char* __sanity;
@ -129,7 +129,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
void
locale::facet::_S_create_c_locale(__c_locale& __cloc, const char* __s,
locale::facet::_S_create_c_locale(__c_locale& __cloc, const char* __s,
__c_locale __old)
{
__cloc = __newlocale(1 << LC_ALL, __s, __old);
@ -145,7 +145,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
locale::facet::_S_destroy_c_locale(__c_locale& __cloc)
{
if (__cloc && _S_get_c_locale() != __cloc)
__freelocale(__cloc);
__freelocale(__cloc);
}
__c_locale
@ -261,18 +261,18 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
const char* const category_names[6 + _GLIBCXX_NUM_CATEGORIES] =
{
"LC_CTYPE",
"LC_CTYPE",
"LC_NUMERIC",
"LC_TIME",
"LC_COLLATE",
"LC_TIME",
"LC_COLLATE",
"LC_MONETARY",
"LC_MESSAGES",
"LC_PAPER",
"LC_NAME",
"LC_MESSAGES",
"LC_PAPER",
"LC_NAME",
"LC_ADDRESS",
"LC_TELEPHONE",
"LC_MEASUREMENT",
"LC_IDENTIFICATION"
"LC_TELEPHONE",
"LC_MEASUREMENT",
"LC_IDENTIFICATION"
};
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -41,7 +41,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#ifdef _GLIBCXX_USE_WCHAR_T
codecvt_base::result
codecvt<wchar_t, char, mbstate_t>::
do_out(state_type& __state, const intern_type* __from,
do_out(state_type& __state, const intern_type* __from,
const intern_type* __from_end, const intern_type*& __from_next,
extern_type* __to, extern_type* __to_end,
extern_type*& __to_next) const
@ -111,12 +111,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__uselocale(__old);
#endif
return __ret;
return __ret;
}
codecvt_base::result
codecvt<wchar_t, char, mbstate_t>::
do_in(state_type& __state, const extern_type* __from,
do_in(state_type& __state, const extern_type* __from,
const extern_type* __from_end, const extern_type*& __from_next,
intern_type* __to, intern_type* __to_end,
intern_type*& __to_next) const
@ -160,12 +160,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
break;
}
__from_next = __from;
__state = __tmp_state;
__state = __tmp_state;
__ret = error;
}
else if (__from_next && __from_next < __from_chunk_end)
{
// It is unclear what to return in this case (see DR 382).
// It is unclear what to return in this case (see DR 382).
__to_next += __conv;
__ret = partial;
}
@ -180,7 +180,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
if (__to_next < __to_end)
{
// XXX Probably wrong for stateful encodings
__tmp_state = __state;
__tmp_state = __state;
++__from_next;
*__to_next++ = L'\0';
}
@ -193,10 +193,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__uselocale(__old);
#endif
return __ret;
return __ret;
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_encoding() const throw()
{
@ -212,9 +212,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__uselocale(__old);
#endif
return __ret;
}
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_max_length() const throw()
{
@ -228,8 +228,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#endif
return __ret;
}
int
int
codecvt<wchar_t, char, mbstate_t>::
do_length(state_type& __state, const extern_type* __from,
const extern_type* __end, size_t __max) const
@ -244,10 +244,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// mbsnrtowcs is *very* fast but stops if encounters NUL characters:
// in case we advance past it and then continue, in a loop.
// NB: mbsnrtowcs is a GNU extension
// A dummy internal buffer is needed in order for mbsnrtocws to consider
// its fourth parameter (it wouldn't with NULL as first parameter).
wchar_t* __to = static_cast<wchar_t*>(__builtin_alloca(sizeof(wchar_t)
wchar_t* __to = static_cast<wchar_t*>(__builtin_alloca(sizeof(wchar_t)
* __max));
while (__from < __end && __max)
{
@ -281,7 +281,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
if (!__from)
__from = __from_chunk_end;
__ret += __from - __tmp_from;
__max -= __conv;
@ -299,7 +299,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__uselocale(__old);
#endif
return __ret;
return __ret;
}
#endif

View File

@ -38,30 +38,30 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// These are basically extensions to char_traits, and perhaps should
// be put there instead of here.
template<>
int
collate<char>::_M_compare(const char* __one,
int
collate<char>::_M_compare(const char* __one,
const char* __two) const throw()
{
{
int __cmp = __strcoll_l(__one, __two, _M_c_locale_collate);
return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0);
}
template<>
size_t
collate<char>::_M_transform(char* __to, const char* __from,
collate<char>::_M_transform(char* __to, const char* __from,
size_t __n) const throw()
{ return __strxfrm_l(__to, __from, __n, _M_c_locale_collate); }
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
int
collate<wchar_t>::_M_compare(const wchar_t* __one,
int
collate<wchar_t>::_M_compare(const wchar_t* __one,
const wchar_t* __two) const throw()
{
int __cmp = __wcscoll_l(__one, __two, _M_c_locale_collate);
return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0);
}
template<>
size_t
collate<wchar_t>::_M_transform(wchar_t* __to, const wchar_t* __from,

View File

@ -39,12 +39,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: The other ctype<char> specializations are in src/locale.cc and
// various /config/os/* files.
ctype_byname<char>::ctype_byname(const char* __s, size_t __refs)
: ctype<char>(0, false, __refs)
{
: ctype<char>(0, false, __refs)
{
if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0)
{
this->_S_destroy_c_locale(this->_M_c_locale_ctype);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
this->_S_create_c_locale(this->_M_c_locale_ctype, __s);
this->_M_toupper = this->_M_c_locale_ctype->__ctype_toupper;
this->_M_tolower = this->_M_c_locale_ctype->__ctype_tolower;
this->_M_table = this->_M_c_locale_ctype->__ctype_b;
@ -54,7 +54,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype_byname<char>::~ctype_byname()
{ }
#ifdef _GLIBCXX_USE_WCHAR_T
#ifdef _GLIBCXX_USE_WCHAR_T
ctype<wchar_t>::__wmask_type
ctype<wchar_t>::_M_convert_to_wmask(const mask __m) const throw()
{
@ -102,7 +102,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __ret;
}
wchar_t
ctype<wchar_t>::do_toupper(wchar_t __c) const
{ return __towupper_l(__c, _M_c_locale_ctype); }
@ -117,11 +117,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __hi;
}
wchar_t
ctype<wchar_t>::do_tolower(wchar_t __c) const
{ return __towlower_l(__c, _M_c_locale_ctype); }
const wchar_t*
ctype<wchar_t>::do_tolower(wchar_t* __lo, const wchar_t* __hi) const
{
@ -136,7 +136,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
bool
ctype<wchar_t>::
do_is(mask __m, wchar_t __c) const
{
{
// The case of __m == ctype_base::space is particularly important,
// due to its use in many istream functions. Therefore we deal with
// it first, exploiting the knowledge that on GNU systems _M_bit[5]
@ -161,17 +161,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
break;
}
}
return __ret;
return __ret;
}
const wchar_t*
const wchar_t*
ctype<wchar_t>::
do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const
{
for (; __lo < __hi; ++__vec, ++__lo)
{
// Highest bitmask in ctype_base == 11
const size_t __bitmasksize = 11;
const size_t __bitmasksize = 11;
mask __m = 0;
for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur)
if (__iswctype_l(*__lo, _M_wmask[__bitcur], _M_c_locale_ctype))
@ -180,8 +180,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
return __hi;
}
const wchar_t*
const wchar_t*
ctype<wchar_t>::
do_scan_is(mask __m, const wchar_t* __lo, const wchar_t* __hi) const
{
@ -204,7 +204,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
do_widen(char __c) const
{ return _M_widen[static_cast<unsigned char>(__c)]; }
const char*
const char*
ctype<wchar_t>::
do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const
{
@ -230,12 +230,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
__uselocale(__old);
#endif
return (__c == EOF ? __dfault : static_cast<char>(__c));
return (__c == EOF ? __dfault : static_cast<char>(__c));
}
const wchar_t*
ctype<wchar_t>::
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault,
char* __dest) const
{
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
@ -292,7 +292,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_widen[__j] = btowc(__j);
for (size_t __k = 0; __k <= 11; ++__k)
{
{
_M_bit[__k] = static_cast<mask>(_ISbit(__k));
_M_wmask[__k] = _M_convert_to_wmask(_M_bit[__k]);
}

View File

@ -42,9 +42,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// Construct and return valid pattern consisting of some combination of:
// space none symbol sign value
money_base::pattern
money_base::_S_construct_pattern(char __precedes, char __space,
money_base::_S_construct_pattern(char __precedes, char __space,
char __posn) throw()
{
{
pattern __ret;
// This insanely complicated routine attempts to construct a valid
@ -52,7 +52,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// if (__precedes) symbol -> value
// else value -> symbol
// if (__space) space
// else none
@ -137,7 +137,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
if (__precedes)
{
__ret.field[0] = sign;
__ret.field[1] = symbol;
__ret.field[1] = symbol;
if (__space)
{
__ret.field[2] = space;
@ -145,7 +145,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
{
__ret.field[2] = value;
__ret.field[2] = value;
__ret.field[3] = none;
}
}
@ -207,9 +207,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
#endif
template<>
template<>
void
moneypunct<char, true>::_M_initialize_moneypunct(__c_locale __cloc,
moneypunct<char, true>::_M_initialize_moneypunct(__c_locale __cloc,
const char*)
{
if (!_M_data)
@ -239,9 +239,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
else
{
// Named locale.
_M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT,
_M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT,
__cloc));
_M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP,
_M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP,
__cloc));
// Check for NULL, which implies no fractional digits.
@ -252,7 +252,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_decimal_point = '.';
}
else
_M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS,
_M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS,
__cloc));
const char* __cgroup = __nl_langinfo_l(__MON_GROUPING, __cloc);
@ -264,11 +264,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
char* __group = 0;
char* __ps = 0;
char* __ns = 0;
const char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc));
const char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc));
__try
{
size_t __len;
// Check for NULL, which implies no grouping.
if (_M_data->_M_thousands_sep == '\0')
{
@ -358,9 +358,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
}
template<>
template<>
void
moneypunct<char, false>::_M_initialize_moneypunct(__c_locale __cloc,
moneypunct<char, false>::_M_initialize_moneypunct(__c_locale __cloc,
const char*)
{
if (!_M_data)
@ -390,9 +390,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
else
{
// Named locale.
_M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT,
_M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT,
__cloc));
_M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP,
_M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP,
__cloc));
// Check for NULL, which implies no fractional digits.
@ -509,7 +509,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
}
template<>
template<>
moneypunct<char, true>::~moneypunct()
{
if (_M_data->_M_grouping_size)
@ -524,7 +524,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
delete _M_data;
}
template<>
template<>
moneypunct<char, false>::~moneypunct()
{
if (_M_data->_M_grouping_size)
@ -540,9 +540,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
template<>
void
moneypunct<wchar_t, true>::_M_initialize_moneypunct(__c_locale __cloc,
moneypunct<wchar_t, true>::_M_initialize_moneypunct(__c_locale __cloc,
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
const char*)
#else
@ -604,7 +604,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_decimal_point = L'.';
}
else
_M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS,
_M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS,
__cloc));
const char* __cgroup = __nl_langinfo_l(__MON_GROUPING, __cloc);
@ -657,9 +657,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_positive_sign = L"";
_M_data->_M_positive_sign_size =
_M_data->_M_positive_sign_size =
wcslen(_M_data->_M_positive_sign);
__len = strlen(__cnegsign);
if (!__nposn)
_M_data->_M_negative_sign = L"()";
@ -672,9 +672,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_negative_sign = L"";
_M_data->_M_negative_sign_size =
_M_data->_M_negative_sign_size =
wcslen(_M_data->_M_negative_sign);
// _Intl == true.
__len = strlen(__ccurr);
if (__len)
@ -694,7 +694,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data = 0;
delete [] __group;
delete [] __wcs_ps;
delete [] __wcs_ns;
delete [] __wcs_ns;
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
__uselocale(__old);
#else
@ -702,8 +702,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
delete [] __sav;
#endif
__throw_exception_again;
}
}
char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc));
char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc));
char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc));
@ -723,7 +723,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
}
template<>
template<>
void
moneypunct<wchar_t, false>::_M_initialize_moneypunct(__c_locale __cloc,
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
@ -840,7 +840,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_positive_sign = L"";
_M_data->_M_positive_sign_size =
_M_data->_M_positive_sign_size =
wcslen(_M_data->_M_positive_sign);
__len = strlen(__cnegsign);
@ -855,7 +855,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
_M_data->_M_negative_sign = L"";
_M_data->_M_negative_sign_size =
_M_data->_M_negative_sign_size =
wcslen(_M_data->_M_negative_sign);
// _Intl == true.
@ -877,7 +877,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data = 0;
delete [] __group;
delete [] __wcs_ps;
delete [] __wcs_ns;
delete [] __wcs_ns;
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
__uselocale(__old);
#else
@ -906,7 +906,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
}
template<>
template<>
moneypunct<wchar_t, true>::~moneypunct()
{
if (_M_data->_M_grouping_size)
@ -921,7 +921,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
delete _M_data;
}
template<>
template<>
moneypunct<wchar_t, false>::~moneypunct()
{
if (_M_data->_M_grouping_size)

View File

@ -35,7 +35,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
template<>
void
numpunct<char>::_M_initialize_numpunct(__c_locale __cloc)
{
@ -61,9 +61,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
else
{
// Named locale.
_M_data->_M_decimal_point = *(__nl_langinfo_l(DECIMAL_POINT,
_M_data->_M_decimal_point = *(__nl_langinfo_l(DECIMAL_POINT,
__cloc));
_M_data->_M_thousands_sep = *(__nl_langinfo_l(THOUSANDS_SEP,
_M_data->_M_thousands_sep = *(__nl_langinfo_l(THOUSANDS_SEP,
__cloc));
// Check for NULL, which implies no grouping.
@ -111,17 +111,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_falsename = "false";
_M_data->_M_falsename_size = 5;
}
template<>
template<>
numpunct<char>::~numpunct()
{
if (_M_data->_M_grouping_size)
delete [] _M_data->_M_grouping;
delete _M_data;
}
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
template<>
void
numpunct<wchar_t>::_M_initialize_numpunct(__c_locale __cloc)
{
@ -204,7 +204,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_data->_M_falsename_size = 5;
}
template<>
template<>
numpunct<wchar_t>::~numpunct()
{
if (_M_data->_M_grouping_size)

View File

@ -39,7 +39,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
__timepunct<char>::
_M_put(char* __s, size_t __maxlen, const char* __format,
_M_put(char* __s, size_t __maxlen, const char* __format,
const tm* __tm) const throw()
{
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
@ -47,7 +47,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_c_locale_timepunct);
#else
char* __old = setlocale(LC_ALL, 0);
const size_t __llen = strlen(__old) + 1;
const size_t __llen = strlen(__old) + 1;
char* __sav = new char[__llen];
memcpy(__sav, __old, __llen);
setlocale(LC_ALL, _M_name_timepunct);
@ -60,7 +60,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__s[0] = '\0';
}
template<>
template<>
void
__timepunct<char>::_M_initialize_timepunct(__c_locale __cloc)
{
@ -130,7 +130,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
{
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
_M_data->_M_date_format = __nl_langinfo_l(D_FMT, __cloc);
_M_data->_M_date_era_format = __nl_langinfo_l(ERA_D_FMT, __cloc);
@ -195,7 +195,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<>
void
__timepunct<wchar_t>::
_M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format,
_M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format,
const tm* __tm) const throw()
{
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
@ -216,7 +216,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__s[0] = L'\0';
}
template<>
template<>
void
__timepunct<wchar_t>::_M_initialize_timepunct(__c_locale __cloc)
{
@ -286,7 +286,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
else
{
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
_M_c_locale_timepunct = _S_clone_c_locale(__cloc);
union { char *__s; wchar_t *__w; } __u;

View File

@ -39,21 +39,21 @@ namespace std _GLIBCXX_VISIBILITY(default)
_GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _CharT>
__timepunct<_CharT>::__timepunct(size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
__timepunct<_CharT>::__timepunct(size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
_M_name_timepunct(_S_get_c_name())
{ _M_initialize_timepunct(); }
template<typename _CharT>
__timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs)
: facet(__refs), _M_data(__cache), _M_c_locale_timepunct(0),
__timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs)
: facet(__refs), _M_data(__cache), _M_c_locale_timepunct(0),
_M_name_timepunct(_S_get_c_name())
{ _M_initialize_timepunct(); }
template<typename _CharT>
__timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s,
size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
size_t __refs)
: facet(__refs), _M_data(0), _M_c_locale_timepunct(0),
_M_name_timepunct(0)
{
if (__builtin_strcmp(__s, _S_get_c_name()) != 0)
@ -78,11 +78,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _CharT>
__timepunct<_CharT>::~__timepunct()
{
{
if (_M_name_timepunct != _S_get_c_name())
delete [] _M_name_timepunct;
delete _M_data;
_S_destroy_c_locale(_M_c_locale_timepunct);
delete _M_data;
_S_destroy_c_locale(_M_c_locale_timepunct);
}
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -30,7 +30,7 @@
#include <locale>
namespace std _GLIBCXX_VISIBILITY(default)
namespace std _GLIBCXX_VISIBILITY(default)
{
void
locale::facet::_S_create_c_locale(__c_locale&, const char*, __c_locale*)
@ -44,7 +44,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
locale::facet::_S_clone_c_locale(__c_locale&) throw()
{ return __c_locale(); }
template<>
template<>
void
numpunct<char>::_M_initialize_numpunct(__c_locale)
{
@ -55,9 +55,9 @@ namespace std _GLIBCXX_VISIBILITY(default)
_M_truename = "true";
_M_falsename = "false";
}
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
template<>
void
numpunct<wchar_t>::_M_initialize_numpunct(__c_locale)
{
@ -70,7 +70,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
}
#endif
template<>
template<>
void
moneypunct<char>::_M_initialize_moneypunct(__c_locale)
{
@ -87,7 +87,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
}
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
template<>
void
moneypunct<wchar_t>::_M_initialize_moneypunct(__c_locale)
{

View File

@ -35,11 +35,11 @@ namespace std _GLIBCXX_VISIBILITY(default)
// Specializations
template<>
string
messages<char>::do_get(catalog __c, int __setid, int __msgid,
messages<char>::do_get(catalog __c, int __setid, int __msgid,
const string& __dfault) const
{
nl_catd __nlc = reinterpret_cast<nl_catd>(__c);
return string(catgets(__nlc, __setid, __msgid, __dfault.c_str()));
return string(catgets(__nlc, __setid, __msgid, __dfault.c_str()));
}
#ifdef _GLIBCXX_USE_WCHAR_T
@ -48,7 +48,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
messages<wchar_t>::do_get(catalog, int, int, const wstring& __dfault) const
{
nl_catd __nlc = reinterpret_cast<nl_catd>(__c);
char* __msg = catgets(__nlc, __setid, __msgid,
char* __msg = catgets(__nlc, __setid, __msgid,
_M_convert_to_char(__dfault));
return _M_convert_from_char(__msg);
}

View File

@ -39,8 +39,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// Non-virtual member functions.
template<typename _CharT>
typename messages<_CharT>::catalog
messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc,
typename messages<_CharT>::catalog
messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc,
const char*) const
{ return this->do_open(__s, __loc); }
@ -50,25 +50,25 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{ }
template<typename _CharT>
typename messages<_CharT>::catalog
messages<_CharT>::do_open(const basic_string<char>& __s,
typename messages<_CharT>::catalog
messages<_CharT>::do_open(const basic_string<char>& __s,
const locale&) const
{ return reinterpret_cast<catalog>(catopen(__s.c_str(), NL_CAT_LOCALE)); }
template<typename _CharT>
typename messages<_CharT>::string_type
messages<_CharT>::do_get(catalog __c, int __setid, int __msgid,
typename messages<_CharT>::string_type
messages<_CharT>::do_get(catalog __c, int __setid, int __msgid,
const string_type& __dfault) const
{
nl_catd __nlc = reinterpret_cast<nl_catd>(__c);
char* __msg = catgets(__nlc, __setid, __msgid,
char* __msg = catgets(__nlc, __setid, __msgid,
_M_convert_to_char(__dfault));
return _M_convert_from_char(__msg);
}
template<typename _CharT>
void
messages<_CharT>::do_close(catalog __c) const
void
messages<_CharT>::do_close(catalog __c) const
{ catclose(reinterpret_cast<nl_catd>(__c)); }
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -25,9 +25,9 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information as gleaned from /usr/include/ctype.h
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION

View File

@ -41,7 +41,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
bool
ctype<char>::
is(mask __m, char __c) const
{
{
if(_M_table)
return _M_table[static_cast<unsigned char>(__c)] & __m;
else

View File

@ -25,11 +25,11 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information as gleaned from /usr/include/ctype.h on FreeBSD 3.4,
// 4.0 and all versions of the CVS managed file at:
// :pserver:anoncvs@anoncvs.freebsd.org:/home/ncvs/src/include/ctype.h
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION

View File

@ -37,28 +37,28 @@ namespace std _GLIBCXX_VISIBILITY(default)
_GLIBCXX_BEGIN_NAMESPACE_VERSION
// Information as gleaned from /usr/include/ctype.h
const ctype_base::mask*
ctype<char>::classic_table() throw()
{ return 0; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
_M_narrow_ok = 0;
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -84,7 +84,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return ::tolower((int) __c); }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -30,10 +30,10 @@
//
// ISO C++ 14882: 22.1 Locales
//
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
// functions go in ctype.cc
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -41,7 +41,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
bool
ctype<char>::
is(mask __m, char __c) const
{
{
if (_M_table)
return _M_table[static_cast<unsigned char>(__c)] & __m;
else
@ -111,7 +111,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
return __low;
}
#ifdef _GLIBCXX_USE_WCHAR_T
#ifdef _GLIBCXX_USE_WCHAR_T
inline bool
ctype<wchar_t>::
do_is(mask __m, wchar_t __c) const
@ -119,7 +119,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
return __istype (__c, __m);
}
inline const wchar_t*
inline const wchar_t*
ctype<wchar_t>::
do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const
{
@ -129,8 +129,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
| blank);
return __hi;
}
inline const wchar_t*
inline const wchar_t*
ctype<wchar_t>::
do_scan_is(mask __m, const wchar_t* __lo, const wchar_t* __hi) const
{

View File

@ -25,12 +25,12 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information as gleaned from /usr/include/ctype.h on NetBSD.
// Full details can be found from the CVS files at:
// anoncvs@anoncvs.netbsd.org:/cvsroot/basesrc/include/ctype.h
// See www.netbsd.org for details of access.
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION

View File

@ -44,23 +44,23 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::classic_table() throw()
{ return _C_ctype_ + 1; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
_M_narrow_ok = 0;
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -86,7 +86,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return ::tolower((int) __c); }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -30,10 +30,10 @@
//
// ISO C++ 14882: 22.1 Locales
//
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
// functions go in ctype.cc
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION

View File

@ -25,7 +25,7 @@
//
// ISO C++ 14882: 22.1 Locales
//
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -34,7 +34,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
struct ctype_base
{
typedef unsigned short mask;
// Non-standard typedefs.
typedef unsigned char * __to_type;

View File

@ -93,10 +93,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
no_lock_available = ENOLCK,
#ifdef _GLIBCXX_HAVE_ENODATA
no_message_available = ENODATA,
no_message_available = ENODATA,
#endif
// no_message = ENOMSG,
// no_message = ENOMSG,
// no_protocol_option = ENOPROTOOPT,
no_space_on_device = ENOSPC,

View File

@ -42,23 +42,23 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::classic_table() throw()
{ return 0; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
_M_narrow_ok = 0;
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -84,7 +84,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return ::tolower((int) __c); }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -30,10 +30,10 @@
//
// ISO C++ 14882: 22.1 Locales
//
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
// functions go in ctype.cc
// The following definitions are portable, but insanely slow. If one
// cares at all about performance, then specialized ctype
// functionality should be added for the native os in question: see
@ -48,13 +48,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
bool
ctype<char>::
is(mask __m, char __c) const
{
{
if (_M_table)
return _M_table[static_cast<unsigned char>(__c)] & __m;
else
{
bool __ret = false;
const size_t __bitmasksize = 15;
const size_t __bitmasksize = 15;
size_t __bitcur = 0; // Lowest bitmask in ctype_base == 0
for (; __bitcur <= __bitmasksize; ++__bitcur)
{
@ -112,7 +112,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
return __ret;
}
}
const char*
ctype<char>::
is(const char* __low, const char* __high, mask* __vec) const
@ -123,12 +123,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
else
{
// Highest bitmask in ctype_base == 11.
const size_t __bitmasksize = 15;
const size_t __bitmasksize = 15;
for (;__low < __high; ++__vec, ++__low)
{
mask __m = 0;
// Lowest bitmask in ctype_base == 0
size_t __i = 0;
size_t __i = 0;
for (;__i <= __bitmasksize; ++__i)
{
const mask __bit = static_cast<mask>(1 << __i);

View File

@ -93,10 +93,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
no_lock_available = ENOLCK,
#ifdef _GLIBCXX_HAVE_ENODATA
no_message_available = ENODATA,
no_message_available = ENODATA,
#endif
no_message = ENOMSG,
no_message = ENOMSG,
no_protocol_option = ENOPROTOOPT,
no_space_on_device = ENOSPC,

View File

@ -25,9 +25,9 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Default information, may not be appropriate for specific host.
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -40,7 +40,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: Offsets into ctype<char>::_M_table force a particular size
// on the mask type. Because of this, we don't use an enum.
typedef unsigned int mask;
typedef unsigned int mask;
static const mask upper = _ISUPPER;
static const mask lower = _ISLOWER;
static const mask alpha = _ISALPHA;

View File

@ -42,23 +42,23 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::classic_table() throw()
{ return __SB_masks; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : (const mask *) __SB_masks)
{
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : (const mask *) __SB_masks)
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
_M_narrow_ok = 0;
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : (const mask *) __SB_masks)
{
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : (const mask *) __SB_masks)
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -84,7 +84,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return ::tolower((int) __c); }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -21,7 +21,7 @@
// a copy of the GCC Runtime Library Exception along with this program;
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>.
/** @file bits/ctype_inline.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{locale}
@ -33,7 +33,7 @@
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
// functions go in ctype.cc
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -56,7 +56,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::
scan_is(mask __m, const char* __low, const char* __high) const
{
while (__low < __high
while (__low < __high
&& !(_M_table[static_cast<unsigned char>(*__low)] & __m))
++__low;
return __low;
@ -66,7 +66,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::
scan_not(mask __m, const char* __low, const char* __high) const
{
while (__low < __high
while (__low < __high
&& (_M_table[static_cast<unsigned char>(*__low)] & __m) != 0)
++__low;
return __low;

View File

@ -43,7 +43,7 @@
everyone else, they put them into a non-standard header
<inttypes.h>. Ugh.
<inttypes.h> defines a variety of things, some of which we
<inttypes.h> defines a variety of things, some of which we
probably do not want. So we don't want to include it here.
Luckily we can just declare strtoll and strtoull with the
@ -60,7 +60,7 @@
#ifdef __cplusplus
namespace std
{
extern "C"
extern "C"
{
#ifndef __LP64__
__extension__ long long strtoll (const char *, char **, int)
@ -80,7 +80,7 @@ namespace std
#define _GLIBCXX_USE_LONG_LONG 1
// HPUX on IA64 requires vtable to be 64 bit aligned even at 32 bit
// mode. We need to pad the vtable structure to achieve this.
// mode. We need to pad the vtable structure to achieve this.
#if !defined(_LP64) && defined (__ia64__)
#define _GLIBCXX_VTABLE_PADDING 8
typedef long int __padding_type;
@ -105,7 +105,7 @@ typedef long int __padding_type;
// The strtold function is obsolete and not C99 conformant on PA HP-UX.
// It returns plus or minus _LDBL_MAX instead of plus or minus HUGE_VALL
// if the correct value would cause overflow. It doesn't handle "inf",
// "infinity" and "nan". It is not thread safe.
// "infinity" and "nan". It is not thread safe.
#if defined (__hppa__)
#define _GLIBCXX_HAVE_BROKEN_STRTOLD 1
#endif

View File

@ -46,7 +46,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: Offsets into ctype<char>::_M_table force a particular size
// on the mask type. Because of this, we don't use an enum.
typedef unsigned short mask;
typedef unsigned short mask;
static const mask upper = 1 << 0;
static const mask lower = 1 << 1;
static const mask alpha = 1 << 2;

View File

@ -46,7 +46,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: Offsets into ctype<char>::_M_table force a particular size
// on the mask type. Because of this, we don't use an enum.
typedef unsigned short mask;
typedef unsigned short mask;
static const mask upper = 1 << 0;
static const mask lower = 1 << 1;
static const mask alpha = 1 << 2;

View File

@ -25,7 +25,7 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information as gleaned from /usr/include/ctype.h
namespace std _GLIBCXX_VISIBILITY(default)

View File

@ -37,26 +37,26 @@ namespace std _GLIBCXX_VISIBILITY(default)
_GLIBCXX_BEGIN_NAMESPACE_VERSION
// Information as gleaned from /usr/include/ctype.h
const ctype_base::mask*
ctype<char>::classic_table() throw()
{ return 0; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL), _M_table(__table ? __table : _Ctype)
{
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
_M_narrow_ok = 0;
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL), _M_table(__table ? __table : _Ctype)
{
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -82,7 +82,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return ::tolower((int) __c); }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -30,10 +30,10 @@
//
// ISO C++ 14882: 22.1 Locales
//
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
// functions go in ctype.cc
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION

View File

@ -25,7 +25,7 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information as gleaned from /usr/include/ctype.h. Looks like this
// only works with solaris2.7 and solaris2.8. Thanks for not changing
// things, sun engineers!
@ -42,7 +42,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: Offsets into ctype<char>::_M_table force a particular size
// on the mask type. Because of this, we don't use an enum.
typedef unsigned int mask;
typedef unsigned int mask;
static const mask upper = _ISUPPER;
static const mask lower = _ISLOWER;
static const mask alpha = _ISALPHA;

View File

@ -37,17 +37,17 @@ namespace std _GLIBCXX_VISIBILITY(default)
_GLIBCXX_BEGIN_NAMESPACE_VERSION
// Information as gleaned from /usr/include/ctype.h
const ctype_base::mask*
const ctype_base::mask*
ctype<char>::classic_table() throw()
{ return __ctype_mask; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(__trans_upper), _M_tolower(__trans_lower),
_M_table(__table ? __table : classic_table())
{
_M_table(__table ? __table : classic_table())
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -55,10 +55,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(__trans_upper), _M_tolower(__trans_lower),
_M_table(__table ? __table : classic_table())
{
_M_table(__table ? __table : classic_table())
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -84,7 +84,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return _M_tolower[static_cast<unsigned char>(__c)]; }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -21,7 +21,7 @@
// a copy of the GCC Runtime Library Exception along with this program;
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>.
/** @file bits/ctype_inline.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{locale}
@ -33,7 +33,7 @@
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
// functions go in ctype.cc
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -56,7 +56,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::
scan_is(mask __m, const char* __low, const char* __high) const
{
while (__low < __high
while (__low < __high
&& !(_M_table[static_cast<unsigned char>(*__low)] & __m))
++__low;
return __low;
@ -66,7 +66,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::
scan_not(mask __m, const char* __low, const char* __high) const
{
while (__low < __high
while (__low < __high
&& (_M_table[static_cast<unsigned char>(*__low)] & __m) != 0)
++__low;
return __low;

View File

@ -25,9 +25,9 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information as gleaned from /usr/include/ctype.h
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -40,7 +40,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: Offsets into ctype<char>::_M_table force a particular size
// on the mask type. Because of this, we don't use an enum.
typedef unsigned short mask;
typedef unsigned short mask;
static const mask upper = _ISupper;
static const mask lower = _ISlower;
static const mask alpha = _ISalpha;

View File

@ -53,8 +53,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
return __ret;
}
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del)
{
char* __old = setlocale(LC_CTYPE, NULL);
@ -105,7 +105,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return _M_tolower[static_cast<unsigned char>(__c)]; }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -30,10 +30,10 @@
//
// ISO C++ 14882: 22.1 Locales
//
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
// functions go in ctype.cc
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -56,7 +56,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::
scan_is(mask __m, const char* __low, const char* __high) const
{
while (__low < __high
while (__low < __high
&& !(_M_table[static_cast<unsigned char>(*__low)] & __m))
++__low;
return __low;
@ -66,7 +66,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::
scan_not(mask __m, const char* __low, const char* __high) const
{
while (__low < __high
while (__low < __high
&& (_M_table[static_cast<unsigned char>(*__low)] & __m) != 0)
++__low;
return __low;

View File

@ -42,9 +42,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::classic_table() throw()
{ return __C_ctype_b; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_c_locale_ctype(_S_get_c_locale()),
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_c_locale_ctype(_S_get_c_locale()),
_M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0)
{
_M_toupper = __C_ctype_toupper;
@ -55,7 +55,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_c_locale_ctype(_S_get_c_locale()),
: facet(__refs), _M_c_locale_ctype(_S_get_c_locale()),
_M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0)
{
_M_toupper = __C_ctype_toupper;
@ -84,7 +84,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return _M_tolower[static_cast<unsigned char>(__c)]; }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -25,9 +25,9 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information extracted from target/h/ctype.h.
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
@ -40,7 +40,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: Offsets into ctype<char>::_M_table force a particular size
// on the mask type. Because of this, we don't use an enum.
typedef unsigned char mask;
typedef unsigned char mask;
static const mask upper = _C_UPPER;
static const mask lower = _C_LOWER;
static const mask alpha = _C_UPPER | _C_LOWER;

View File

@ -42,23 +42,23 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::classic_table() throw()
{ return __ctype; }
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
_M_narrow_ok = 0;
}
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
: facet(__refs), _M_del(__table != 0 && __del),
_M_toupper(NULL), _M_tolower(NULL),
_M_table(__table ? __table : classic_table())
{
{
memset(_M_widen, 0, sizeof(_M_widen));
_M_widen_ok = 0;
memset(_M_narrow, 0, sizeof(_M_narrow));
@ -84,7 +84,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::do_tolower(char __c) const
{ return __tolower(__c); }
const char*
const char*
ctype<char>::do_tolower(char* __low, const char* __high) const
{
while (__low < __high)

View File

@ -30,7 +30,7 @@
//
// ISO C++ 14882: 22.1 Locales
//
// Information as gleaned from target/h/ctype.h
// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
@ -58,7 +58,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
ctype<char>::
scan_is(mask __m, const char* __low, const char* __high) const
{
while (__low < __high
while (__low < __high
&& !(__ctype[static_cast<unsigned char>(*__low)] & __m))
++__low;
return __low;

View File

@ -77,7 +77,7 @@ cxx98_sources = \
compatibility.cc \
compatibility-debug_list.cc \
compatibility-debug_list-2.cc \
${ldbl_compat_sources}
${ldbl_compat_sources}
cxx11_sources = \
compatibility-c++0x.cc \
@ -141,7 +141,7 @@ compatibility-condvar.o: compatibility-condvar.cc
$(CXXCOMPILE) -std=gnu++11 -c $<
# A note on compatibility and static libraries.
#
#
# static lib == linked against only this version, should not need compat
# shared lib == linked against potentially all compat versions
#
@ -150,7 +150,7 @@ compatibility-condvar.o: compatibility-condvar.cc
#
# In the sub-directories of libsupc++, src/c++98, src/c++11, only
# -prefer-pic objects are generated for the convenience libraries.
#
#
# In the main src directory, make shared and static objects just for
# the compat libraries. Shared objects are compiled with -prefer-pic
# -D_GLIBCXX_SHARED and in the .libs sub-directory, static objects are
@ -187,7 +187,7 @@ AM_CXXFLAGS = \
# correct solution is to add `--tag CXX' to LTCXXCOMPILE and maybe
# CXXLINK, just after $(LIBTOOL), so that libtool doesn't have to
# attempt to infer which configuration to use.
#
#
# The second tag argument, `--tag disable-shared` means that libtool
# only compiles each source once, for static objects. In actuality,
# glibcxx_lt_pic_flag and glibcxx_compiler_shared_flag are added to

View File

@ -402,7 +402,7 @@ cxx98_sources = \
compatibility.cc \
compatibility-debug_list.cc \
compatibility-debug_list-2.cc \
${ldbl_compat_sources}
${ldbl_compat_sources}
cxx11_sources = \
compatibility-c++0x.cc \
@ -430,7 +430,7 @@ libstdc___la_LDFLAGS = \
libstdc___la_LINK = $(CXXLINK) $(libstdc___la_LDFLAGS)
# A note on compatibility and static libraries.
#
#
# static lib == linked against only this version, should not need compat
# shared lib == linked against potentially all compat versions
#
@ -439,7 +439,7 @@ libstdc___la_LINK = $(CXXLINK) $(libstdc___la_LDFLAGS)
#
# In the sub-directories of libsupc++, src/c++98, src/c++11, only
# -prefer-pic objects are generated for the convenience libraries.
#
#
# In the main src directory, make shared and static objects just for
# the compat libraries. Shared objects are compiled with -prefer-pic
# -D_GLIBCXX_SHARED and in the .libs sub-directory, static objects are
@ -477,7 +477,7 @@ AM_CXXFLAGS = \
# correct solution is to add `--tag CXX' to LTCXXCOMPILE and maybe
# CXXLINK, just after $(LIBTOOL), so that libtool doesn't have to
# attempt to infer which configuration to use.
#
#
# The second tag argument, `--tag disable-shared` means that libtool
# only compiles each source once, for static objects. In actuality,
# glibcxx_lt_pic_flag and glibcxx_compiler_shared_flag are added to

View File

@ -115,7 +115,7 @@ vpath % $(top_srcdir)/src/c++11
libc__11convenience_la_SOURCES = $(sources) $(inst_sources)
# Use special rules for the hashtable.cc file so that all
# the generated template functions are also instantiated.
# the generated template functions are also instantiated.
hashtable_c++0x.lo: hashtable_c++0x.cc
$(LTCXXCOMPILE) -fimplicit-templates -c $<
hashtable_c++0x.o: hashtable_c++0x.cc
@ -149,7 +149,7 @@ AM_MAKEFLAGS = \
# correct solution is to add `--tag CXX' to LTCXXCOMPILE and maybe
# CXXLINK, just after $(LIBTOOL), so that libtool doesn't have to
# attempt to infer which configuration to use.
#
#
# The second tag argument, `--tag disable-shared` means that libtool
# only compiles each source once, for static objects. In actuality,
# glibcxx_lt_pic_flag and glibcxx_compiler_shared_flag are added to

View File

@ -449,7 +449,7 @@ AM_MAKEFLAGS = \
# correct solution is to add `--tag CXX' to LTCXXCOMPILE and maybe
# CXXLINK, just after $(LIBTOOL), so that libtool doesn't have to
# attempt to infer which configuration to use.
#
#
# The second tag argument, `--tag disable-shared` means that libtool
# only compiles each source once, for static objects. In actuality,
# glibcxx_lt_pic_flag and glibcxx_compiler_shared_flag are added to
@ -729,7 +729,7 @@ ctype_members.cc: ${glibcxx_srcdir}/$(CCTYPE_CC)
vpath % $(top_srcdir)/src/c++11
# Use special rules for the hashtable.cc file so that all
# the generated template functions are also instantiated.
# the generated template functions are also instantiated.
hashtable_c++0x.lo: hashtable_c++0x.cc
$(LTCXXCOMPILE) -fimplicit-templates -c $<
hashtable_c++0x.o: hashtable_c++0x.cc

View File

@ -75,7 +75,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
#endif
}
constexpr bool steady_clock::is_steady;
steady_clock::time_point

View File

@ -64,7 +64,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{
bool
test_and_set(memory_order) noexcept;
void
clear(memory_order) noexcept;
};

View File

@ -86,7 +86,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
#ifdef _GLIBCXX_USE_WCHAR_T
template<>
struct hash<wstring>
{
{
size_t operator()(wstring) const;
};

View File

@ -41,7 +41,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
namespace chrono
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
// NB: Default configuration was no realtime.
struct system_clock
{

View File

@ -32,7 +32,7 @@ namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
namespace
namespace
{
typedef char fake_collate_c[sizeof(std::collate<char>)]
__attribute__ ((aligned(__alignof__(std::collate<char>))));
@ -50,7 +50,7 @@ namespace
typedef char fake_money_get_c[sizeof(money_get<char>)]
__attribute__ ((aligned(__alignof__(money_get<char>))));
fake_money_get_c money_get_c;
typedef char fake_money_put_c[sizeof(money_put<char>)]
__attribute__ ((aligned(__alignof__(money_put<char>))));
fake_money_put_c money_put_c;
@ -80,7 +80,7 @@ namespace
typedef char fake_money_get_w[sizeof(money_get<wchar_t>)]
__attribute__ ((aligned(__alignof__(money_get<wchar_t>))));
fake_money_get_w money_get_w;
typedef char fake_money_put_w[sizeof(money_put<wchar_t>)]
__attribute__ ((aligned(__alignof__(money_put<wchar_t>))));
fake_money_put_w money_put_w;
@ -161,7 +161,7 @@ namespace
_M_init_facet_unchecked(new money_put<wchar_t>);
_M_init_facet_unchecked(new time_get<wchar_t>);
_M_init_facet_unchecked(new std::messages<wchar_t>(__cloc, __s));
#endif
#endif
}
// TODO should be in another file
@ -178,7 +178,7 @@ namespace
__ret.reserve(128);
__ret += _S_categories[0];
__ret += '=';
__ret += _M_impl->_M_names[0];
__ret += _M_impl->_M_names[0];
for (size_t __i = 1; __i < _S_categories_size; ++__i)
{
__ret += ';';

View File

@ -42,17 +42,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// These came from c++98/misc-inst.cc, repeat them for COW string
// string related to iostreams.
template
basic_istream<char>&
template
basic_istream<char>&
operator>>(basic_istream<char>&, string&);
template
basic_ostream<char>&
template
basic_ostream<char>&
operator<<(basic_ostream<char>&, const string&);
template
basic_istream<char>&
template
basic_istream<char>&
getline(basic_istream<char>&, string&, char);
template
basic_istream<char>&
template
basic_istream<char>&
getline(basic_istream<char>&, string&);
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -46,17 +46,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// XXX these came from c++98/misc-inst.cc, repeat them for COW string
// string related to iostreams
template
basic_istream<wchar_t>&
template
basic_istream<wchar_t>&
operator>>(basic_istream<wchar_t>&, wstring&);
template
basic_ostream<wchar_t>&
template
basic_ostream<wchar_t>&
operator<<(basic_ostream<wchar_t>&, const wstring&);
template
basic_istream<wchar_t>&
template
basic_istream<wchar_t>&
getline(basic_istream<wchar_t>&, wstring&, wchar_t);
template
basic_istream<wchar_t>&
template
basic_istream<wchar_t>&
getline(basic_istream<wchar_t>&, wstring&);
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -45,17 +45,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// Definitions for locale::id of standard facets that are specialized.
locale::id ctype<char>::id;
#ifdef _GLIBCXX_USE_WCHAR_T
#ifdef _GLIBCXX_USE_WCHAR_T
locale::id ctype<wchar_t>::id;
#endif
const size_t ctype<char>::table_size;
ctype<char>::~ctype()
{
{
_S_destroy_c_locale(_M_c_locale_ctype);
if (_M_del)
delete[] this->table();
if (_M_del)
delete[] this->table();
}
// Fill in the narrowing cache and flag whether all values are
@ -69,7 +69,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
for (size_t __i = 0; __i < sizeof(_M_narrow); ++__i)
__tmp[__i] = __i;
do_narrow(__tmp, __tmp + sizeof(__tmp), 0, _M_narrow);
_M_narrow_ok = 1;
if (__builtin_memcmp(__tmp, _M_narrow, sizeof(_M_narrow)))
_M_narrow_ok = 2;
@ -92,7 +92,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
for (size_t __i = 0; __i < sizeof(_M_widen); ++__i)
__tmp[__i] = __i;
do_widen(__tmp, __tmp + sizeof(__tmp), _M_widen);
_M_widen_ok = 1;
// Set _M_widen_ok to 2 if memcpy can't be used.
if (__builtin_memcmp(__tmp, _M_widen, sizeof(_M_widen)))
@ -100,22 +100,22 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
#ifdef _GLIBCXX_USE_WCHAR_T
ctype<wchar_t>::ctype(size_t __refs)
: __ctype_abstract_base<wchar_t>(__refs),
ctype<wchar_t>::ctype(size_t __refs)
: __ctype_abstract_base<wchar_t>(__refs),
_M_c_locale_ctype(_S_get_c_locale()), _M_narrow_ok(false)
{ _M_initialize_ctype(); }
ctype<wchar_t>::ctype(__c_locale __cloc, size_t __refs)
ctype<wchar_t>::ctype(__c_locale __cloc, size_t __refs)
: __ctype_abstract_base<wchar_t>(__refs),
_M_c_locale_ctype(_S_clone_c_locale(__cloc)), _M_narrow_ok(false)
{ _M_initialize_ctype(); }
ctype<wchar_t>::~ctype()
ctype<wchar_t>::~ctype()
{ _S_destroy_c_locale(_M_c_locale_ctype); }
ctype_byname<wchar_t>::ctype_byname(const char* __s, size_t __refs)
: ctype<wchar_t>(__refs)
{
: ctype<wchar_t>(__refs)
{
if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0)
{
this->_S_destroy_c_locale(this->_M_c_locale_ctype);
@ -124,7 +124,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
}
ctype_byname<wchar_t>::~ctype_byname()
ctype_byname<wchar_t>::~ctype_byname()
{ }
#endif

View File

@ -74,21 +74,21 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
bool ios_base::Init::_S_synced_with_stdio = true;
ios_base::ios_base() throw()
: _M_precision(), _M_width(), _M_flags(), _M_exception(),
_M_streambuf_state(), _M_callbacks(0), _M_word_zero(),
: _M_precision(), _M_width(), _M_flags(), _M_exception(),
_M_streambuf_state(), _M_callbacks(0), _M_word_zero(),
_M_word_size(_S_local_word_size), _M_word(_M_local_word), _M_ios_locale()
{
// Do nothing: basic_ios::init() does it.
// Do nothing: basic_ios::init() does it.
// NB: _M_callbacks and _M_word must be zero for non-initialized
// ios_base to go through ~ios_base gracefully.
}
// 27.4.2.7 ios_base constructors/destructors
ios_base::~ios_base()
{
_M_call_callbacks(erase_event);
_M_dispose_callbacks();
if (_M_word != _M_local_word)
if (_M_word != _M_local_word)
{
delete [] _M_word;
_M_word = 0;
@ -96,16 +96,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
// 27.4.2.5 ios_base storage functions
int
int
ios_base::xalloc() throw()
{
// Implementation note: Initialize top to zero to ensure that
// initialization occurs before main() is started.
static _Atomic_word _S_top = 0;
static _Atomic_word _S_top = 0;
return __gnu_cxx::__exchange_and_add_dispatch(&_S_top, 1) + 4;
}
void
void
ios_base::register_callback(event_callback __fn, int __index)
{ _M_callbacks = new _Callback_list(__fn, __index, _M_callbacks); }
@ -140,9 +140,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_word_zero._M_pword = 0;
return _M_word_zero;
}
for (int __i = 0; __i < _M_word_size; __i++)
for (int __i = 0; __i < _M_word_size; __i++)
__words[__i] = _M_word[__i];
if (_M_word && _M_word != _M_local_word)
if (_M_word && _M_word != _M_local_word)
{
delete [] _M_word;
_M_word = 0;
@ -165,21 +165,21 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
return _M_word[__ix];
}
void
void
ios_base::_M_call_callbacks(event __e) throw()
{
_Callback_list* __p = _M_callbacks;
while (__p)
{
__try
{ (*__p->_M_fn) (__e, *this, __p->_M_index); }
__catch(...)
__try
{ (*__p->_M_fn) (__e, *this, __p->_M_index); }
__catch(...)
{ }
__p = __p->_M_next;
}
}
void
void
ios_base::_M_dispose_callbacks(void) throw()
{
_Callback_list* __p = _M_callbacks;

View File

@ -40,7 +40,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#ifdef _GLIBCXX_USE_WCHAR_T
template class _Setfill<wchar_t>;
template _Setfill<wchar_t> setfill(wchar_t);
template class basic_iostream<wchar_t>;
template class basic_iostream<wchar_t>;
#endif
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -50,7 +50,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template istream& operator>>(istream&, _Setw);
template istream& istream::_M_extract(unsigned short&);
template istream& istream::_M_extract(unsigned int&);
template istream& istream::_M_extract(unsigned int&);
template istream& istream::_M_extract(long&);
template istream& istream::_M_extract(unsigned long&);
template istream& istream::_M_extract(bool&);
@ -77,7 +77,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template wistream& operator>>(wistream&, _Setw);
template wistream& wistream::_M_extract(unsigned short&);
template wistream& wistream::_M_extract(unsigned int&);
template wistream& wistream::_M_extract(unsigned int&);
template wistream& wistream::_M_extract(long&);
template wistream& wistream::_M_extract(unsigned long&);
template wistream& wistream::_M_extract(bool&);

View File

@ -163,7 +163,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// wchar_t
// This used to be problematic...
#ifdef _GLIBCXX_USE_WCHAR_T
#ifdef _GLIBCXX_USE_WCHAR_T
const bool numeric_limits<wchar_t>::is_specialized;
const int numeric_limits<wchar_t>::digits;
const int numeric_limits<wchar_t>::digits10;

View File

@ -76,13 +76,13 @@ _GLIBCXX_BEGIN_NAMESPACE_LDBL_OR_CXX11
template
ostreambuf_iterator<C>
money_put<C, ostreambuf_iterator<C> >::
_M_insert<true>(ostreambuf_iterator<C>, ios_base&, C,
_M_insert<true>(ostreambuf_iterator<C>, ios_base&, C,
const string_type&) const;
template
ostreambuf_iterator<C>
money_put<C, ostreambuf_iterator<C> >::
_M_insert<false>(ostreambuf_iterator<C>, ios_base&, C,
_M_insert<false>(ostreambuf_iterator<C>, ios_base&, C,
const string_type&) const;
_GLIBCXX_END_NAMESPACE_LDBL_OR_CXX11
@ -110,7 +110,7 @@ _GLIBCXX_BEGIN_NAMESPACE_LDBL
istreambuf_iterator<C>
num_get<C, istreambuf_iterator<C> >::
_M_extract_int(istreambuf_iterator<C>, istreambuf_iterator<C>,
ios_base&, ios_base::iostate&,
ios_base&, ios_base::iostate&,
unsigned short&) const;
template
@ -149,39 +149,39 @@ _GLIBCXX_BEGIN_NAMESPACE_LDBL
template
ostreambuf_iterator<C>
num_put<C, ostreambuf_iterator<C> >::
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
long) const;
template
ostreambuf_iterator<C>
num_put<C, ostreambuf_iterator<C> >::
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
unsigned long) const;
#ifdef _GLIBCXX_USE_LONG_LONG
template
ostreambuf_iterator<C>
num_put<C, ostreambuf_iterator<C> >::
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
long long) const;
template
ostreambuf_iterator<C>
num_put<C, ostreambuf_iterator<C> >::
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
_M_insert_int(ostreambuf_iterator<C>, ios_base&, C,
unsigned long long) const;
#endif
template
ostreambuf_iterator<C>
num_put<C, ostreambuf_iterator<C> >::
_M_insert_float(ostreambuf_iterator<C>, ios_base&, C, char,
_M_insert_float(ostreambuf_iterator<C>, ios_base&, C, char,
double) const;
template
ostreambuf_iterator<C>
num_put<C, ostreambuf_iterator<C> >::
_M_insert_float(ostreambuf_iterator<C>, ios_base&, C, char,
_M_insert_float(ostreambuf_iterator<C>, ios_base&, C, char,
long double) const;
#endif
_GLIBCXX_END_NAMESPACE_LDBL
@ -206,7 +206,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
template class messages<C>;
template class messages_byname<C>;
_GLIBCXX_END_NAMESPACE_CXX11
// ctype
ctype_byname<C>::ctype_byname(const string& __s, size_t __refs)
: ctype_byname(__s.c_str(), __refs) { }
@ -215,7 +215,7 @@ _GLIBCXX_END_NAMESPACE_CXX11
inline template class __ctype_abstract_base<C>;
template class ctype_byname<C>;
#endif
// codecvt
#if ! _GLIBCXX_USE_CXX11_ABI
inline template class __codecvt_abstract_base<C, char, mbstate_t>;
@ -230,126 +230,126 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
template class collate<C>;
template class collate_byname<C>;
_GLIBCXX_END_NAMESPACE_CXX11
// use_facet
#if ! _GLIBCXX_USE_CXX11_ABI
template
const ctype<C>&
const ctype<C>&
use_facet<ctype<C> >(const locale&);
template
const codecvt<C, char, mbstate_t>&
const codecvt<C, char, mbstate_t>&
use_facet<codecvt<C, char, mbstate_t> >(const locale&);
#endif
template
const collate<C>&
const collate<C>&
use_facet<collate<C> >(const locale&);
template
const numpunct<C>&
const numpunct<C>&
use_facet<numpunct<C> >(const locale&);
#if ! _GLIBCXX_USE_CXX11_ABI
template
const num_put<C>&
template
const num_put<C>&
use_facet<num_put<C> >(const locale&);
template
const num_get<C>&
template
const num_get<C>&
use_facet<num_get<C> >(const locale&);
#endif
template
const moneypunct<C, true>&
const moneypunct<C, true>&
use_facet<moneypunct<C, true> >(const locale&);
template
const moneypunct<C, false>&
const moneypunct<C, false>&
use_facet<moneypunct<C, false> >(const locale&);
template
const money_put<C>&
template
const money_put<C>&
use_facet<money_put<C> >(const locale&);
template
const money_get<C>&
template
const money_get<C>&
use_facet<money_get<C> >(const locale&);
#if ! _GLIBCXX_USE_CXX11_ABI
template
const __timepunct<C>&
const __timepunct<C>&
use_facet<__timepunct<C> >(const locale&);
template
const time_put<C>&
template
const time_put<C>&
use_facet<time_put<C> >(const locale&);
#endif
template
const time_get<C>&
template
const time_get<C>&
use_facet<time_get<C> >(const locale&);
template
const messages<C>&
template
const messages<C>&
use_facet<messages<C> >(const locale&);
// has_facet
#if ! _GLIBCXX_USE_CXX11_ABI
template
template
bool
has_facet<ctype<C> >(const locale&);
template
template
bool
has_facet<codecvt<C, char, mbstate_t> >(const locale&);
#endif
template
template
bool
has_facet<collate<C> >(const locale&);
template
template
bool
has_facet<numpunct<C> >(const locale&);
#if ! _GLIBCXX_USE_CXX11_ABI
template
template
bool
has_facet<num_put<C> >(const locale&);
template
template
bool
has_facet<num_get<C> >(const locale&);
#endif
template
template
bool
has_facet<moneypunct<C> >(const locale&);
template
template
bool
has_facet<money_put<C> >(const locale&);
template
template
bool
has_facet<money_get<C> >(const locale&);
#if ! _GLIBCXX_USE_CXX11_ABI
template
template
bool
has_facet<__timepunct<C> >(const locale&);
template
template
bool
has_facet<time_put<C> >(const locale&);
#endif
template
template
bool
has_facet<time_get<C> >(const locale&);
template
template
bool
has_facet<messages<C> >(const locale&);
@ -358,7 +358,7 @@ _GLIBCXX_END_NAMESPACE_CXX11
// locale functions.
template
C*
__add_grouping<C>(C*, C, char const*, size_t,
__add_grouping<C>(C*, C, char const*, size_t,
C const*, C const*);
template class __pad<C, char_traits<C> >;
@ -371,7 +371,7 @@ _GLIBCXX_END_NAMESPACE_CXX11
#ifdef _GLIBCXX_USE_LONG_LONG
template
int
__int_to_char(C*, unsigned long long, const C*,
__int_to_char(C*, unsigned long long, const C*,
ios_base::fmtflags, bool);
#endif
#endif

View File

@ -30,7 +30,7 @@
namespace std _GLIBCXX_VISIBILITY(default)
{
namespace placeholders
namespace placeholders
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
extern const _Placeholder<1> _1{};

View File

@ -44,9 +44,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#ifdef _GLIBCXX_USE_WCHAR_T
template class basic_stringbuf<wchar_t>;
template class basic_istringstream<wchar_t>;
template class basic_ostringstream<wchar_t>;
template class basic_stringstream<wchar_t>;
template class basic_istringstream<wchar_t>;
template class basic_ostringstream<wchar_t>;
template class basic_stringstream<wchar_t>;
#endif
_GLIBCXX_END_NAMESPACE_VERSION

View File

@ -53,7 +53,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template S operator+(C, const S&);
template S operator+(const S&, const S&);
// Only one template keyword allowed here.
// Only one template keyword allowed here.
// See core issue #46 (NAD)
// http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_closed.html#46
template
@ -62,17 +62,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template
S::basic_string(const C*, const C*, const allocator<C>&);
template
template
S::basic_string(S::iterator, S::iterator, const allocator<C>&);
#if _GLIBCXX_USE_CXX11_ABI
template
template
void
S::_M_construct(S::iterator, S::iterator, forward_iterator_tag);
template
template
void
S::_M_construct(S::const_iterator, S::const_iterator,
S::_M_construct(S::const_iterator, S::const_iterator,
forward_iterator_tag);
template
@ -85,9 +85,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#else // !_GLIBCXX_USE_CXX11_ABI
template
C*
S::_S_construct(S::iterator, S::iterator,
template
C*
S::_S_construct(S::iterator, S::iterator,
const allocator<C>&, forward_iterator_tag);
template

View File

@ -33,8 +33,8 @@
namespace
{
using std::string;
using std::string;
struct generic_error_category : public std::error_category
{
virtual const char*
@ -42,7 +42,7 @@ namespace
{ return "generic"; }
_GLIBCXX_DEFAULT_ABI_TAG
virtual string
virtual string
message(int i) const
{
// XXX locale issues: how does one get or set loc.
@ -77,28 +77,28 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
error_category::~error_category() noexcept = default;
const error_category&
const error_category&
_V2::system_category() noexcept { return system_category_instance; }
const error_category&
const error_category&
_V2::generic_category() noexcept { return generic_category_instance; }
system_error::~system_error() noexcept = default;
error_condition
error_condition
error_category::default_error_condition(int __i) const noexcept
{ return error_condition(__i, *this); }
bool
bool
error_category::equivalent(int __i,
const error_condition& __cond) const noexcept
{ return default_error_condition(__i) == __cond; }
bool
bool
error_category::equivalent(const error_code& __code, int __i) const noexcept
{ return *this == __code.category() && __code.value() == __i; }
error_condition
error_condition
error_code::default_error_condition() const noexcept
{ return category().default_error_condition(value()); }

View File

@ -23,7 +23,7 @@
include $(top_srcdir)/fragment.am
# Convenience library for C++98 runtime.
noinst_LTLIBRARIES = libc++98convenience.la
noinst_LTLIBRARIES = libc++98convenience.la
headers =
@ -209,7 +209,7 @@ concept-inst.o: concept-inst.cc
$(CXXCOMPILE) -D_GLIBCXX_CONCEPT_CHECKS -fimplicit-templates -c $<
# Use special rules for parallel mode compilation.
PARALLEL_FLAGS = -D_GLIBCXX_PARALLEL
PARALLEL_FLAGS = -D_GLIBCXX_PARALLEL
parallel_settings.lo: parallel_settings.cc
$(LTCXXCOMPILE) $(PARALLEL_FLAGS) -c $<
parallel_settings.o: parallel_settings.cc
@ -243,7 +243,7 @@ AM_MAKEFLAGS = \
# correct solution is to add `--tag CXX' to LTCXXCOMPILE and maybe
# CXXLINK, just after $(LIBTOOL), so that libtool doesn't have to
# attempt to infer which configuration to use.
#
#
# The second tag argument, `--tag disable-shared` means that libtool
# only compiles each source once, for static objects. In actuality,
# glibcxx_lt_pic_flag and glibcxx_compiler_shared_flag are added to

Some files were not shown because too many files have changed in this diff Show More