Boost logo

Boost :

From: Michel André (michel.andre_at_[hidden])
Date: 2003-03-30 15:22:28


I get the following errors when compiling with the lexical_cast version in
CVS on MSVC 7.0 do I have to enable wchar_t support on the command line or
disable it via DISABLE_WIDE_CHAR_SUPPORT or whats the solution. I tried to
read up on the new lexical_cast woes with the 1.30 release but failed to
find something.

C:\Packages\boost\work\boost\lexical_cast.hpp(161) : error C2679: binary '='
: no operator found which takes a right-hand operand of type
'std::basic_stringstream<_Elem,_Traits,_Alloc>::_Mystr' (or there is no
acceptable conversion)
        with
        [
            _Elem=wchar_t,
            _Traits=std::char_traits<wchar_t>,
            _Alloc=std::allocator<wchar_t>
        ]
        C:\Packages\boost\work\boost\lexical_cast.hpp(157) : while compiling
class-template member function 'bool
boost::detail::lexical_stream<Target,Source>::operator >>(std::string &)'
        with
        [
            Target=std::string,
            Source=boost::socket::port_t
        ]
        C:\Packages\boost\work\boost\lexical_cast.hpp(189) : see reference
to class template instantiation
'boost::detail::lexical_stream<Target,Source>' being compiled
        with
        [
            Target=std::string,
            Source=boost::socket::port_t
        ]
        server_test.cpp(128) : see reference to function template
instantiation 'Target
boost::lexical_cast?$@V?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@
2@@std@@G(Source)' being compiled
        with
        [
            Target=std::string,
            Source=boost::socket::port_t
        ]

btw boost::socket::port_t is unsigned short which gets mixed up with
wchar_t.

Regards
/Michel


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