Re: [Boost-bugs] [Boost C++ Libraries] #2228: signed overflow problem in weighted_sum on VC9.0

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #2228: signed overflow problem in weighted_sum on VC9.0
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2008-08-19 18:27:24


#2228: signed overflow problem in weighted_sum on VC9.0
---------------------------+------------------------------------------------
  Reporter: pavol_droba | Owner: eric_niebler
      Type: Bugs | Status: closed
 Milestone: Boost 1.36.0 | Component: accumulator
   Version: Boost 1.36.0 | Severity: Problem
Resolution: invalid | Keywords:
---------------------------+------------------------------------------------

Comment(by eric_niebler):

 I understand your point, but I still disagree. I'm not going to get into
 guessing what a "better" type to hold the result is. It can be argued from
 the other side ... that using an int to hold the result of an
 (int*unsigned) can overflow and wrap. There is no good solution. Following
 the rules of C++ is simply the best (as in least surprising, easiest to
 explain) thing to do.

-- 
Ticket URL: <http://svn.boost.org/trac/boost/ticket/2228#comment:3>
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:49:58 UTC