summaryrefslogtreecommitdiff
path: root/boost/random
diff options
context:
space:
mode:
Diffstat (limited to 'boost/random')
-rw-r--r--boost/random/detail/signed_unsigned_tools.hpp2
-rw-r--r--boost/random/discrete_distribution.hpp8
-rw-r--r--boost/random/piecewise_constant_distribution.hpp8
-rw-r--r--boost/random/piecewise_linear_distribution.hpp8
-rw-r--r--boost/random/seed_seq.hpp6
5 files changed, 16 insertions, 16 deletions
diff --git a/boost/random/detail/signed_unsigned_tools.hpp b/boost/random/detail/signed_unsigned_tools.hpp
index 3c81cf49c1..988cfb84db 100644
--- a/boost/random/detail/signed_unsigned_tools.hpp
+++ b/boost/random/detail/signed_unsigned_tools.hpp
@@ -73,7 +73,7 @@ struct add<T1, T2, /* signed */ true>
if (y >= 0)
return T2(x) + y;
// y < 0
- if (x >= T1(-(y+1))) // result >= 0 after subtraction
+ if (x > T1(-(y+1))) // result >= 0 after subtraction
// avoid the nasty two's complement edge case for y == min()
return T2(x - T1(-(y+1)) - 1);
// abs(x) < abs(y), thus T2 able to represent x
diff --git a/boost/random/discrete_distribution.hpp b/boost/random/discrete_distribution.hpp
index d6a4ede59c..bbdc055383 100644
--- a/boost/random/discrete_distribution.hpp
+++ b/boost/random/discrete_distribution.hpp
@@ -7,7 +7,7 @@
*
* See http://www.boost.org for most recent version including documentation.
*
- * $Id: discrete_distribution.hpp 71018 2011-04-05 21:27:52Z steven_watanabe $
+ * $Id: discrete_distribution.hpp 79771 2012-07-27 18:15:55Z jewillco $
*/
#ifndef BOOST_RANDOM_DISCRETE_DISTRIBUTION_HPP_INCLUDED
@@ -25,7 +25,7 @@
#include <boost/random/detail/operators.hpp>
#include <boost/random/detail/vector_io.hpp>
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
#include <initializer_list>
#endif
@@ -69,7 +69,7 @@ public:
{
normalize();
}
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
/**
* If wl.size() == 0, equivalent to the default constructor.
* Otherwise, the values of the @c initializer_list represent
@@ -190,7 +190,7 @@ public:
{
init(first, last);
}
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
/**
* Constructs a @c discrete_distribution from a @c std::initializer_list.
* If the @c initializer_list is empty, equivalent to the default
diff --git a/boost/random/piecewise_constant_distribution.hpp b/boost/random/piecewise_constant_distribution.hpp
index 30339c0d19..dbeadae3a9 100644
--- a/boost/random/piecewise_constant_distribution.hpp
+++ b/boost/random/piecewise_constant_distribution.hpp
@@ -7,7 +7,7 @@
*
* See http://www.boost.org for most recent version including documentation.
*
- * $Id: piecewise_constant_distribution.hpp 71018 2011-04-05 21:27:52Z steven_watanabe $
+ * $Id: piecewise_constant_distribution.hpp 79771 2012-07-27 18:15:55Z jewillco $
*/
#ifndef BOOST_RANDOM_PIECEWISE_CONSTANT_DISTRIBUTION_HPP_INCLUDED
@@ -22,7 +22,7 @@
#include <boost/random/detail/operators.hpp>
#include <boost/random/detail/vector_io.hpp>
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
#include <initializer_list>
#endif
@@ -84,7 +84,7 @@ public:
}
}
}
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
/**
* Constructs a @c param_type object from an
* initializer_list containing the interval boundaries
@@ -271,7 +271,7 @@ public:
_bins.param(bins_param);
}
}
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
/**
* Constructs a piecewise_constant_distribution from an
* initializer_list containing the interval boundaries
diff --git a/boost/random/piecewise_linear_distribution.hpp b/boost/random/piecewise_linear_distribution.hpp
index 7e67f7dd7a..b7b6860cbc 100644
--- a/boost/random/piecewise_linear_distribution.hpp
+++ b/boost/random/piecewise_linear_distribution.hpp
@@ -7,7 +7,7 @@
*
* See http://www.boost.org for most recent version including documentation.
*
- * $Id: piecewise_linear_distribution.hpp 71018 2011-04-05 21:27:52Z steven_watanabe $
+ * $Id: piecewise_linear_distribution.hpp 79771 2012-07-27 18:15:55Z jewillco $
*/
#ifndef BOOST_RANDOM_PIECEWISE_LINEAR_DISTRIBUTION_HPP_INCLUDED
@@ -24,7 +24,7 @@
#include <boost/random/detail/operators.hpp>
#include <boost/random/detail/vector_io.hpp>
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
#include <initializer_list>
#endif
@@ -89,7 +89,7 @@ public:
}
}
}
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
/**
* Constructs a @c param_type object from an initializer_list
* containing the interval boundaries and a unary function
@@ -278,7 +278,7 @@ public:
init();
}
}
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
/**
* Constructs a piecewise_linear_distribution from an
* initializer_list containing the interval boundaries
diff --git a/boost/random/seed_seq.hpp b/boost/random/seed_seq.hpp
index 557b4fa2ef..44798f21bc 100644
--- a/boost/random/seed_seq.hpp
+++ b/boost/random/seed_seq.hpp
@@ -7,7 +7,7 @@
*
* See http://www.boost.org for most recent version including documentation.
*
- * $Id: seed_seq.hpp 74867 2011-10-09 23:13:31Z steven_watanabe $
+ * $Id: seed_seq.hpp 79771 2012-07-27 18:15:55Z jewillco $
*
*/
@@ -23,7 +23,7 @@
#include <algorithm>
#include <iterator>
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
#include <initializer_list>
#endif
@@ -42,7 +42,7 @@ public:
/** Initializes a seed_seq to hold an empty sequence. */
seed_seq() {}
-#ifndef BOOST_NO_INITIALIZER_LISTS
+#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
/** Initializes the sequence from an initializer_list. */
template<class T>
seed_seq(const std::initializer_list<T>& il) : v(il.begin(), il.end()) {}