Boost logo

Boost Users :

Subject: [Boost-users] boost random uniform real infinite loop
From: Peter Man (plwm2_at_[hidden])
Date: 2011-10-29 20:03:09


Hi,

Recently, I've encountered a problem with the generate_uniform_real
function (the is_integral version) in
boost/random/uniform_real_distribution.hpp.
A bug in my code meant that I was trying to generate a uniform random
number where the min and max bounds were exactly equal.
However, this meant that when on entering the function stated earlier,
an infinite loop is never exited from! Is this a bug in boost::random,
or have I missed something?

Thanks

Peter


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net