This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/55047] operator() in std::exponential_distribution may call log(0)


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55047

--- Comment #4 from paolo at gcc dot gnu.org <paolo at gcc dot gnu.org> 2012-11-01 21:09:57 UTC ---
Author: paolo
Date: Thu Nov  1 21:09:51 2012
New Revision: 193070

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193070
Log:
2012-11-01   Haakan Younes  <hyounes@google.com>
         Paolo Carlini  <paolo.carlini@oracle.com>

    PR libstdc++/55047
    * include/bits/random.h (exponential_distribution<>::operator):
    Fix formula to std::log(result_type(1) - __aurng()).
    * include/bits/random.tcc: Likewise, everywhere.

Modified:
    branches/gcc-4_7-branch/libstdc++-v3/ChangeLog
    branches/gcc-4_7-branch/libstdc++-v3/include/bits/random.h
    branches/gcc-4_7-branch/libstdc++-v3/include/bits/random.tcc


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]