diff options
| -rw-r--r-- | libstdc++-v3/ChangeLog | 6 | ||||
| -rw-r--r-- | libstdc++-v3/include/bits/locale_facets.tcc | 6 |
2 files changed, 11 insertions, 1 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 371360a..62bbca9 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,9 @@ +2007-04-02 Paolo Carlini <pcarlini@suse.de> + + * include/bits/locale_facets.tcc (num_put<>::do_put(iter_type, + ios_base&, char_type, const void*)): Fix for sizeof(const void*) + > sizeof(unsigned long). + 2007-04-01 Andreas Tobler <a.tobler@schweiz.org> * include/tr1/poly_laguerre.tcc: Missing s/__alpha/__alpha1, line 278. diff --git a/libstdc++-v3/include/bits/locale_facets.tcc b/libstdc++-v3/include/bits/locale_facets.tcc index b6feda0..8290d4a 100644 --- a/libstdc++-v3/include/bits/locale_facets.tcc +++ b/libstdc++-v3/include/bits/locale_facets.tcc @@ -1313,8 +1313,12 @@ _GLIBCXX_BEGIN_LDBL_NAMESPACE | ios_base::internal); __io.flags((__flags & __fmt) | (ios_base::hex | ios_base::showbase)); + typedef __gnu_cxx::__conditional_type<(sizeof(const void*) + <= sizeof(unsigned long)), + unsigned long, unsigned long long>::__type _UIntPtrType; + __s = _M_insert_int(__s, __io, __fill, - reinterpret_cast<unsigned long>(__v)); + reinterpret_cast<_UIntPtrType>(__v)); __io.flags(__flags); return __s; } |
