Subject: [Boost-bugs] [Boost C++ Libraries] #12260: Bug: time_fmt does not support for wchar_t on windows
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2016-06-10 12:12:39
#12260: Bug: time_fmt does not support for wchar_t on windows
------------------------------+---------------------
Reporter: l_ting@⦠| Owner: viboes
Type: Bugs | Status: new
Milestone: To Be Determined | Component: chrono
Version: Boost 1.59.0 | Severity: Problem
Keywords: |
------------------------------+---------------------
chrono time_fmt does not support wchar_t on Windows platform. The reason
is:
In the constructor of ios_base_data_aux, the time_fmt and duration_fmt has
been initialized as char_t which causes the visual studio to report
errors. These initialization is unnecessary. As a result, comment these
two lines of initialization resolves the issue.
ios_base_data_aux() :
time_fmt(""),
duration_fmt("")
{}
---------- Error message from visual studio---------
1>c:\home\svn\commonlibs\3rdparty\boost-v1.59.0\include\boost-
1_59\boost\chrono\io\ios_base_state.hpp(119) : error C2664:
'std::basic_string<_Elem,_Traits,_Ax>::basic_string(std::basic_string<_Elem,_Traits,_Ax>::_Has_debug_it)'
: cannot convert parameter 1 from 'const char [1]' to
'std::basic_string<_Elem,_Traits,_Ax>::_Has_debug_it'
1> with
1> [
1> _Elem=wchar_t,
1> _Traits=std::char_traits<wchar_t>,
1> _Ax=std::allocator<wchar_t>
1> ]
1> Constructor for struct
'std::basic_string<_Elem,_Traits,_Ax>::_Has_debug_it' is declared
'explicit'
1> with
1> [
1> _Elem=wchar_t,
1> _Traits=std::char_traits<wchar_t>,
1> _Ax=std::allocator<wchar_t>
1> ]
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/12260> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:20 UTC