Opened 10 years ago
Closed 5 years ago
#6936 closed Bugs (worksforme)
Warning 4244 in posix_time_zone.hpp
Reported by: | Owned by: | James E. King, III | |
---|---|---|---|
Milestone: | To Be Determined | Component: | date_time |
Version: | Boost 1.49.0 | Severity: | Problem |
Keywords: | Cc: |
Description
The warnings:
C:\Dev\Include\boost/date_time/local_time/posix_time_zone.hpp(433) : warning C4244: 'argument' : conversion from 'int' to 'unsigned short', possible loss of data 1> C:\Dev\Include\boost/date_time/local_time/posix_time_zone.hpp(414) : while compiling class template member function 'void boost::local_time::posix_time_zone_base<CharT>::julian_no_leap(const std::basic_string<_Elem,_Traits,_Ax> &,const std::basic_string<_Elem,_Traits,_Ax> &)' 1> with 1> [ 1> CharT=char, 1> _Elem=char, 1> _Traits=std::char_traits<char>, 1> _Ax=std::allocator<char> 1> ] 1> .\MYFILE.cpp(NN) : see reference to class template instantiation 'boost::local_time::posix_time_zone_base<CharT>' being compiled 1> with 1> [ 1> CharT=char 1> ] 1>C:\Dev\Include\boost/date_time/local_time/posix_time_zone.hpp(435) : warning C4244: 'argument' : conversion from 'int' to 'unsigned short', possible loss of data
The line in my code that spawns this:
time_zone_ptr timezone; string tz("UTC0"); // may be changed //... timezone.reset(new posix_time_zone(tz.c_str())); // warnings from here
The warnings occur within body of julian_no_leap()
at the instantiation of new partial_date_dst_rule
, specifically, one each for the start_rule and end_rule constructors.
MSVC 2008, compiling on and for Windows 7.
Change History (3)
comment:1 by , 10 years ago
Component: | None → date_time |
---|---|
Owner: | set to |
comment:2 by , 5 years ago
Owner: | changed from | to
---|
comment:3 by , 5 years ago
Resolution: | → worksforme |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Cannot reproduce this in boost 1.66.0 with msvc-14.1