Subject: [Boost-bugs] [Boost C++ Libraries] #10995: duration_put::put_value truncates fractional part
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-02-04 17:13:10
#10995: duration_put::put_value truncates fractional part
-------------------------------------+---------------------
Reporter: rkawulak | Owner: viboes
Type: Bugs | Status: new
Milestone: To Be Determined | Component: chrono
Version: Boost Development Trunk | Severity: Problem
Keywords: |
-------------------------------------+---------------------
For durations with a floating-point Rep type, duration_put::put_value
truncates fractional part because it makes static_cast<long
int>(d.count()). I guess this code will also be broken if Rep is unsigned
long or larger integral type, causing an overflow.
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/10995> 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:17 UTC