Boost logo

Boost :

From: Terje Slettebø (tslettebo_at_[hidden])
Date: 2003-03-19 03:13:43

>From: "Beman Dawes" <bdawes_at_[hidden]>

> A fresh version of the Win32 regression tests has just been posted. See
> There are seven new fails in date_time tests; presumably all caused by
> lexical_cast.hpp problems. See typical error message below.

I see that all of the new failing tests are on MSVC 6, and it seems the
errors is due to allowing wide character support on MSVC 6. In the Date/Time
tests there are calls such as lexical_cast<unsigned short>(<std::string>),
which lexical_cast on MSVC 6 interprets as trying to convert from
std::string to wchar_t. This also fails in the lexical_cast unit test for

Ok, it seems we may have to exclude wide character support for lexical_cast
on MSVC 6, to avoid breaking Date/Time. I suggest something like:

#if defined(BOOST_NO_STRINGSTREAM) || \
    defined(BOOST_NO_STD_WSTRING) || \
    defined(BOOST_NO_STD_LOCALE) || \
    defined(BOOST_NO_CWCHAR) || \
    defined(BOOST_MSVC) && (BOOST_MSVC <= 1200)

(Testing for BOOST_NO_INTRINSIC_WCHAR_T, instead, would also disable wide
character support on Intel C++ (on Windows), which does work with

I've tested this with Date/Time's testclock.cpp (one of the failing tests)
on MSVC 6 and Intel C++ 7, and it now works.

On the plus side, it appears to now work on g++ 2.95.



Boost list run by bdawes at, gregod at, cpdaniel at, john at