Boost logo

Boost :

From: John Maddock (john_at_[hidden])
Date: 2005-07-19 05:41:40


> But shouldn't this go into some prefix file instead of a postfile file?

We've always used the suffix file for stuff like this that is supposed to be
"generic". Of course if we run into enough problems that might have to
change, but I don't think we're there yet.

> See http://tinyurl.com/aywa7, it failes because of missing support for
> long
> long in the iostream library.

Yep, I can reproduce that via HP-Testdrive, worse the std lib *does* support
numeric_limits<long long>, it's just the iostreams stuff that's missing.

As far as limits_test is concerned there's a workaround for the same problem
with MSVC specifically for that test, I've tested the following patch as a
workaround for gcc, and it fixes the issue for now, but we should probably
add a new config macro or something if there are any other tests affected
though. What do you think? Should this go into 1.33? It's probably a
little close for comfort, Doug?

John.

RCS file: /cvsroot/boost/boost/libs/config/test/limits_test.cpp,v
retrieving revision 1.12
diff -r1.12 limits_test.cpp
56a57,74
> #if (defined(_GLIBCPP_VERSION) || defined(_GLIBCXX_VERSION)) \
> && defined(BOOST_HAS_LONG_LONG) \
> && !defined(_GLIBCPP_USE_LONG_LONG) \
> && !defined(_GLIBCXX_USE_LONG_LONG)
> //
> // Some libstdc++ versions have numeric_limits<long long> but no
> // iostream support for long long. TODO, find a better fix!!
> //
> std::ostream& operator<<(std::ostream& os, long long i )
> {
> return os << static_cast<long double>(i);
> }
> std::ostream& operator<<(std::ostream& os, unsigned long long i )
> {
> return os << static_cast<long double>(i);
> }
> #endif
>


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk