|
Boost Users : |
Subject: Re: [Boost-users] 1.36.0 boost/random/uniform_01 Infinite[?] Loop
From: Dave Steenburgh (dave.steenburgh_at_[hidden])
Date: 2008-10-16 21:01:05
On Thu, Oct 16, 2008 at 7:39 PM, Steven Watanabe <watanabesj_at_[hidden]>wrote:
> The constructor takes a baseGenerator by value, which is then destroyed
> when
> the constructor returns.
>
Believe it or not, I thought about that when I wrote it, and was amazed that
it worked. I promptly forgot about it, and then was severely confused later
when I compiled in debug mode, which for me includes turning off
optimizations. So, is it just pure luck that it works fine in so many
cases? I find it hard to believe that the optimizations would have
eliminated enough stack activity so that it worked reliably.
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