Re: [Boost-bugs] [Boost C++ Libraries] #2819: boost::posix_time::hours, minutes, and seconds assume sizeof(long) == sizeof(int)

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #2819: boost::posix_time::hours, minutes, and seconds assume sizeof(long) == sizeof(int)
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-08-13 14:03:37


#2819: boost::posix_time::hours, minutes, and seconds assume sizeof(long) ==
sizeof(int)
----------------------------------+-----------------------------------------
 Reporter: pelee@… | Owner: az_sw_dude
     Type: Bugs | Status: new
Milestone: Boost 1.39.0 | Component: date_time
  Version: Boost Release Branch | Severity: Problem
 Keywords: |
----------------------------------+-----------------------------------------

Comment(by robert.stewart@…):

 These same warnings occur for GCC 4.3.2 on 64b Linux.

 Just casting to a smaller type is suspect as the caller can supply a value
 in the range of the larger type that overflows the smaller. The cast is
 acceptable if the range is checked, but it may be better to try to bring
 greater consistency to the integer types being used.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/2819#comment:2>
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:01 UTC