2
0
mirror of https://github.com/boostorg/random.git synced 2026-01-19 04:22:17 +00:00

Quickbook: Merge from trunk.

Includes blocks in lists fixes, and some documentation changes.


[SVN r77347]
This commit is contained in:
Daniel James
2012-03-16 08:48:10 +00:00
parent 317d9e56de
commit 28970f0376
8 changed files with 18 additions and 18 deletions

View File

@@ -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_0X_HDR_INITIALIZER_LIST
#include <initializer_list>
#endif
@@ -69,7 +69,7 @@ public:
{
normalize();
}
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_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_0X_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

View File

@@ -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_0X_HDR_INITIALIZER_LIST
#include <initializer_list>
#endif
@@ -84,7 +84,7 @@ public:
}
}
}
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_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_0X_HDR_INITIALIZER_LIST
/**
* Constructs a piecewise_constant_distribution from an
* initializer_list containing the interval boundaries

View File

@@ -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_0X_HDR_INITIALIZER_LIST
#include <initializer_list>
#endif
@@ -89,7 +89,7 @@ public:
}
}
}
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_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_0X_HDR_INITIALIZER_LIST
/**
* Constructs a piecewise_linear_distribution from an
* initializer_list containing the interval boundaries

View File

@@ -23,7 +23,7 @@
#include <algorithm>
#include <iterator>
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_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_0X_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()) {}

View File

@@ -49,7 +49,7 @@ BOOST_AUTO_TEST_CASE(test_constructors) {
boost::random::discrete_distribution<> dist;
CHECK_PROBABILITIES(dist.probabilities(), list_of(1.0));
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST
boost::random::discrete_distribution<> dist_il = { 1, 2, 1, 4 };
CHECK_PROBABILITIES(dist_il.probabilities(), list_of(.125)(.25)(.125)(.5));
#endif
@@ -98,7 +98,7 @@ BOOST_AUTO_TEST_CASE(test_param) {
BOOST_CHECK(param != param_default);
BOOST_CHECK(!(param == param_default));
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST
boost::random::discrete_distribution<>::param_type
parm_il = { 1, 2, 1, 4 };
CHECK_PROBABILITIES(parm_il.probabilities(), list_of(.125)(.25)(.125)(.5));

View File

@@ -50,7 +50,7 @@ BOOST_AUTO_TEST_CASE(test_constructors) {
CHECK_SEQUENCE(dist.densities(), list_of(1.0));
CHECK_SEQUENCE(dist.intervals(), list_of(0.0)(1.0));
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST
boost::random::piecewise_constant_distribution<> dist_il = {
{ 99, 103, 107, 111, 115 },
gen()
@@ -139,7 +139,7 @@ BOOST_AUTO_TEST_CASE(test_param) {
BOOST_CHECK(param != param_default);
BOOST_CHECK(!(param == param_default));
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST
boost::random::piecewise_constant_distribution<>::param_type parm_il = {
{ 99, 103, 107, 111, 115 },
gen()

View File

@@ -51,7 +51,7 @@ BOOST_AUTO_TEST_CASE(test_constructors) {
CHECK_SEQUENCE(dist.intervals(), list_of(0.0)(1.0));
CHECK_SEQUENCE(dist.densities(), list_of(1.0)(1.0));
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST
boost::random::piecewise_linear_distribution<> dist_il = {
{ 99, 103, 107, 111, 115 },
gen()
@@ -143,7 +143,7 @@ BOOST_AUTO_TEST_CASE(test_param) {
BOOST_CHECK(param != param_default);
BOOST_CHECK(!(param == param_default));
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST
boost::random::piecewise_linear_distribution<>::param_type parm_il = {
{ 99, 103, 107, 111, 115 },
gen()

View File

@@ -94,7 +94,7 @@ BOOST_AUTO_TEST_CASE(test_seed_seq) {
BOOST_CHECK_EQUAL_COLLECTIONS(
&param[0], &param[0] + 4, &expected_param[0], &expected_param[0] + 4);
#ifndef BOOST_NO_INITIALIZER_LISTS
#ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST
std::fill_n(&store32[0], 10, 0);
std::fill_n(&store64[0], 10, 0);
std::fill_n(&param[0], 3, 0);