
On Thu, 2 Jun 2005 13:41:49 -0400, Howard Hinnant wrote
On Jun 2, 2005, at 11:17 AM, Rene Rivera wrote:
There are some failures for date_time with CW-9 (and similar errors in CW-8):
CW-9.5 on Mac... http://tinyurl.com/bwhsw http://tinyurl.com/93nh4
CW-9.4 on Windows... http://tinyurl.com/75t78 http://tinyurl.com/br2b5
CW-8.3 on Windows... http://tinyurl.com/85nf5 http://tinyurl.com/9gfpn
They have this as the reason:
"[ J. Garland ] Some older compilers are confused by the template code here. These are new features to date-time in 1.33 and there is no plan to backport to these non-compliant compilers."
Now I don't particularly think of CW-9 as an "older" compiler. So is that really the reason? Or is it just that it hasn't been investigated?
I just took a look at http://tinyurl.com/9y4td and it looks to me like an error in the date_time library. The compile time error is:
Error : illegal operands 'std::basic_istringstream<char, std::char_traits<char>, std::allocator<char>>' >> 'boost::date_time::date_duration<boost::date_time:: duration_traits_adapted>'
And I can't find an operator >> (istream&, date_duration&) in namespace boost::date_time, though I can find one in boost::gregorian. I suspect that this would rightly cause the error.
I haven't looked at any of the other failures.
You can find the code in boost/date_time/gregorian/gregorian_io.hpp - line 100. It's likely, however, that it is macro'ed out because if BOOST_NO_STD_LOCALE is defined this code will not be included. BOOST_NO_STD_LOCALE is controlled by: //boost/config/compiler/metrowerks.hpp // locale support is disabled when linking with the dynamic runtime # ifdef _MSL_NO_LOCALE # define BOOST_NO_STD_LOCALE # endif So my suspicion is that the real issue here is the failure comment is misleading, or the configuration is in error. Do we need to change the config option to let the locale-based code compile? Jeff