Commit dd9db6f8 by Jonathan Wakely Committed by Jonathan Wakely

P0935R0 Eradicating unnecessarily explicit default constructors

Explicit default constructors are problematic, so this change removes
them from <random> and <ext/random>, as per P0935R0.

	* include/bits/random.h (linear_congruential_engine)
	(mersenne_twister_engine, subtract_with_carry_engine, random_device)
	(uniform_real_distribution, normal_distribution)
	(lognormal_distribution, gamma_distribution, chi_squared_distribution)
	(cauchy_distribution, fisher_f_distribution, student_t_distribution)
	(bernoulli_distribution, binomial_distribution,geometric_distribution)
	(negative_binomial_distribution, exponential_distribution)
	(weibull_distribution, extreme_value_distribution): Add non-explicit
	default constructors. Remove default argument for first parameter of
	explicit constructors.
	(piecewise_constant_distribution, piecewise_linear_distribution):
	Make default constructor non-explicit.
	* include/bits/uniform_int_dist.h (uniform_int_distribution): Add
	non-explicit default constructors. Remove default argument for first
	parameter of explicit constructor.
	(simd_fast_mersenne_twister_engine, beta_distribution)
	(rice_distribution, nakagami_distribution, pareto_distribution)
	(k_distribution, arcsine_distribution, hoyt_distribution)
	(triangular_distribution, von_mises_distribution)
	(hypergeometric_distribution, logistic_distribution)
	(uniform_inside_sphere_distribution): Likewise.
	(uniform_on_sphere_distribution): Make default constructor
	non-explicit.
	* testsuite/26_numerics/random/bernoulli_distribution/cons/default.cc:
	Test for non-explicit default constructor. Fix references to standard.
	* testsuite/26_numerics/random/binomial_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/cauchy_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/chi_squared_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/discrete_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/exponential_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/extreme_value_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/fisher_f_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/gamma_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/geometric_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/lognormal_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/negative_binomial_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/normal_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/piecewise_constant_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/piecewise_linear_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/poisson_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/student_t_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/uniform_int_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/uniform_real_distribution/cons/default.cc:
	Likewise.
	* testsuite/26_numerics/random/weibull_distribution/cons/default.cc:
	Likewise.
	* testsuite/ext/random/arcsine_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/beta_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/hoyt_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/hypergeometric_distribution/cons/default.cc:
	Likewise.
	* testsuite/ext/random/k_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/logistic_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/nakagami_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/normal_mv_distribution/cons/default.cc:
	Likewise.
	* testsuite/ext/random/pareto_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/rice_distribution/cons/default.cc: Likewise.
	* testsuite/ext/random/triangular_distribution/cons/default.cc:
	Likewise.
	* testsuite/ext/random/uniform_inside_sphere_distribution/cons/default.cc:
	Likewise.
	* testsuite/ext/random/uniform_on_sphere_distribution/cons/default.cc:
	Likewise.
	* testsuite/ext/random/von_mises_distribution/cons/default.cc:
	Likewise.
	* testsuite/util/testsuite_common_types.h
	(implicitly_default_constructible): New helper.

From-SVN: r261522
parent b80a188b
2018-06-12 Jonathan Wakely <jwakely@redhat.com>
P0935R0 Eradicating unnecessarily explicit default constructors
* include/bits/random.h (linear_congruential_engine)
(mersenne_twister_engine, subtract_with_carry_engine, random_device)
(uniform_real_distribution, normal_distribution)
(lognormal_distribution, gamma_distribution, chi_squared_distribution)
(cauchy_distribution, fisher_f_distribution, student_t_distribution)
(bernoulli_distribution, binomial_distribution,geometric_distribution)
(negative_binomial_distribution, exponential_distribution)
(weibull_distribution, extreme_value_distribution): Add non-explicit
default constructors. Remove default argument for first parameter of
explicit constructors.
(piecewise_constant_distribution, piecewise_linear_distribution):
Make default constructor non-explicit.
* include/bits/uniform_int_dist.h (uniform_int_distribution): Add
non-explicit default constructors. Remove default argument for first
parameter of explicit constructor.
(simd_fast_mersenne_twister_engine, beta_distribution)
(rice_distribution, nakagami_distribution, pareto_distribution)
(k_distribution, arcsine_distribution, hoyt_distribution)
(triangular_distribution, von_mises_distribution)
(hypergeometric_distribution, logistic_distribution)
(uniform_inside_sphere_distribution): Likewise.
(uniform_on_sphere_distribution): Make default constructor
non-explicit.
* testsuite/26_numerics/random/bernoulli_distribution/cons/default.cc:
Test for non-explicit default constructor. Fix references to standard.
* testsuite/26_numerics/random/binomial_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/cauchy_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/chi_squared_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/discrete_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/exponential_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/extreme_value_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/fisher_f_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/gamma_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/geometric_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/lognormal_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/negative_binomial_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/normal_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/piecewise_constant_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/piecewise_linear_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/poisson_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/student_t_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/uniform_int_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/uniform_real_distribution/cons/default.cc:
Likewise.
* testsuite/26_numerics/random/weibull_distribution/cons/default.cc:
Likewise.
* testsuite/ext/random/arcsine_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/beta_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/hoyt_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/hypergeometric_distribution/cons/default.cc:
Likewise.
* testsuite/ext/random/k_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/logistic_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/nakagami_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/normal_mv_distribution/cons/default.cc:
Likewise.
* testsuite/ext/random/pareto_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/rice_distribution/cons/default.cc: Likewise.
* testsuite/ext/random/triangular_distribution/cons/default.cc:
Likewise.
* testsuite/ext/random/uniform_inside_sphere_distribution/cons/default.cc:
Likewise.
* testsuite/ext/random/uniform_on_sphere_distribution/cons/default.cc:
Likewise.
* testsuite/ext/random/von_mises_distribution/cons/default.cc:
Likewise.
* testsuite/util/testsuite_common_types.h
(implicitly_default_constructible): New helper.
2018-06-08 Jonathan Wakely <jwakely@redhat.com> 2018-06-08 Jonathan Wakely <jwakely@redhat.com>
* include/bits/ios_base.h (ios::Init::Init(const Init&)) * include/bits/ios_base.h (ios::Init::Init(const Init&))
......
...@@ -266,13 +266,20 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -266,13 +266,20 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructs a %linear_congruential_engine random number * @brief Constructs a %linear_congruential_engine random number
* generator engine with seed 1.
*/
linear_congruential_engine() : linear_congruential_engine(default_seed)
{ }
/**
* @brief Constructs a %linear_congruential_engine random number
* generator engine with seed @p __s. The default seed value * generator engine with seed @p __s. The default seed value
* is 1. * is 1.
* *
* @param __s The initial seed value. * @param __s The initial seed value.
*/ */
explicit explicit
linear_congruential_engine(result_type __s = default_seed) linear_congruential_engine(result_type __s)
{ seed(__s); } { seed(__s); }
/** /**
...@@ -504,9 +511,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -504,9 +511,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
static constexpr result_type initialization_multiplier = __f; static constexpr result_type initialization_multiplier = __f;
static constexpr result_type default_seed = 5489u; static constexpr result_type default_seed = 5489u;
// constructors and member function // constructors and member functions
mersenne_twister_engine() : mersenne_twister_engine(default_seed) { }
explicit explicit
mersenne_twister_engine(result_type __sd = default_seed) mersenne_twister_engine(result_type __sd)
{ seed(__sd); } { seed(__sd); }
/** /**
...@@ -691,12 +701,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -691,12 +701,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
static constexpr size_t long_lag = __r; static constexpr size_t long_lag = __r;
static constexpr result_type default_seed = 19780503u; static constexpr result_type default_seed = 19780503u;
subtract_with_carry_engine() : subtract_with_carry_engine(default_seed)
{ }
/** /**
* @brief Constructs an explicitly seeded % subtract_with_carry_engine * @brief Constructs an explicitly seeded %subtract_with_carry_engine
* random number generator. * random number generator.
*/ */
explicit explicit
subtract_with_carry_engine(result_type __sd = default_seed) subtract_with_carry_engine(result_type __sd)
{ seed(__sd); } { seed(__sd); }
/** /**
...@@ -1590,24 +1603,19 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1590,24 +1603,19 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// constructors, destructors and member functions // constructors, destructors and member functions
#ifdef _GLIBCXX_USE_RANDOM_TR1 #ifdef _GLIBCXX_USE_RANDOM_TR1
random_device() { _M_init("default"); }
explicit explicit
random_device(const std::string& __token = "default") random_device(const std::string& __token) { _M_init(__token); }
{
_M_init(__token);
}
~random_device() ~random_device()
{ _M_fini(); } { _M_fini(); }
#else #else
random_device() { _M_init("mt19937"); }
explicit explicit
random_device(const std::string& __token = "mt19937") random_device(const std::string& __token = "mt19937")
{ _M_init_pretr1(__token); } { _M_init_pretr1(__token); }
public:
#endif #endif
static constexpr result_type static constexpr result_type
...@@ -1770,12 +1778,18 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1770,12 +1778,18 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructs a uniform_real_distribution object. * @brief Constructs a uniform_real_distribution object.
* *
* The lower bound is set to 0.0 and the upper bound to 1.0
*/
uniform_real_distribution() : uniform_real_distribution(0.0) { }
/**
* @brief Constructs a uniform_real_distribution object.
*
* @param __a [IN] The lower bound of the distribution. * @param __a [IN] The lower bound of the distribution.
* @param __b [IN] The upper bound of the distribution. * @param __b [IN] The upper bound of the distribution.
*/ */
explicit explicit
uniform_real_distribution(_RealType __a = _RealType(0), uniform_real_distribution(_RealType __a, _RealType __b = _RealType(1))
_RealType __b = _RealType(1))
: _M_param(__a, __b) : _M_param(__a, __b)
{ } { }
...@@ -1991,12 +2005,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1991,12 +2005,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}; };
public: public:
normal_distribution() : normal_distribution(0.0) { }
/** /**
* Constructs a normal distribution with parameters @f$mean@f$ and * Constructs a normal distribution with parameters @f$mean@f$ and
* standard deviation. * standard deviation.
*/ */
explicit explicit
normal_distribution(result_type __mean = result_type(0), normal_distribution(result_type __mean,
result_type __stddev = result_type(1)) result_type __stddev = result_type(1))
: _M_param(__mean, __stddev), _M_saved_available(false) : _M_param(__mean, __stddev), _M_saved_available(false)
{ } { }
...@@ -2205,9 +2221,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2205,9 +2221,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_s; _RealType _M_s;
}; };
lognormal_distribution() : lognormal_distribution(0.0) { }
explicit explicit
lognormal_distribution(_RealType __m = _RealType(0), lognormal_distribution(_RealType __m, _RealType __s = _RealType(1))
_RealType __s = _RealType(1))
: _M_param(__m, __s), _M_nd() : _M_param(__m, __s), _M_nd()
{ } { }
...@@ -2426,11 +2443,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2426,11 +2443,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
public: public:
/** /**
* @brief Constructs a gamma distribution with parameters 1 and 1.
*/
gamma_distribution() : gamma_distribution(1.0) { }
/**
* @brief Constructs a gamma distribution with parameters * @brief Constructs a gamma distribution with parameters
* @f$\alpha@f$ and @f$\beta@f$. * @f$\alpha@f$ and @f$\beta@f$.
*/ */
explicit explicit
gamma_distribution(_RealType __alpha_val = _RealType(1), gamma_distribution(_RealType __alpha_val,
_RealType __beta_val = _RealType(1)) _RealType __beta_val = _RealType(1))
: _M_param(__alpha_val, __beta_val), _M_nd() : _M_param(__alpha_val, __beta_val), _M_nd()
{ } { }
...@@ -2630,8 +2652,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2630,8 +2652,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_n; _RealType _M_n;
}; };
chi_squared_distribution() : chi_squared_distribution(1) { }
explicit explicit
chi_squared_distribution(_RealType __n = _RealType(1)) chi_squared_distribution(_RealType __n)
: _M_param(__n), _M_gd(__n / 2) : _M_param(__n), _M_gd(__n / 2)
{ } { }
...@@ -2856,9 +2880,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2856,9 +2880,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_b; _RealType _M_b;
}; };
cauchy_distribution() : cauchy_distribution(0.0) { }
explicit explicit
cauchy_distribution(_RealType __a = _RealType(0), cauchy_distribution(_RealType __a, _RealType __b = 1.0)
_RealType __b = _RealType(1))
: _M_param(__a, __b) : _M_param(__a, __b)
{ } { }
...@@ -3062,8 +3087,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3062,8 +3087,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_n; _RealType _M_n;
}; };
fisher_f_distribution() : fisher_f_distribution(1.0) { }
explicit explicit
fisher_f_distribution(_RealType __m = _RealType(1), fisher_f_distribution(_RealType __m,
_RealType __n = _RealType(1)) _RealType __n = _RealType(1))
: _M_param(__m, __n), _M_gd_x(__m / 2), _M_gd_y(__n / 2) : _M_param(__m, __n), _M_gd_x(__m / 2), _M_gd_y(__n / 2)
{ } { }
...@@ -3285,8 +3312,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3285,8 +3312,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_n; _RealType _M_n;
}; };
student_t_distribution() : student_t_distribution(1.0) { }
explicit explicit
student_t_distribution(_RealType __n = _RealType(1)) student_t_distribution(_RealType __n)
: _M_param(__n), _M_nd(), _M_gd(__n / 2, 2) : _M_param(__n), _M_nd(), _M_gd(__n / 2, 2)
{ } { }
...@@ -3509,13 +3538,18 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3509,13 +3538,18 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
public: public:
/** /**
* @brief Constructs a Bernoulli distribution with likelihood 0.5.
*/
bernoulli_distribution() : bernoulli_distribution(0.5) { }
/**
* @brief Constructs a Bernoulli distribution with likelihood @p p. * @brief Constructs a Bernoulli distribution with likelihood @p p.
* *
* @param __p [IN] The likelihood of a true result being returned. * @param __p [IN] The likelihood of a true result being returned.
* Must be in the interval @f$[0, 1]@f$. * Must be in the interval @f$[0, 1]@f$.
*/ */
explicit explicit
bernoulli_distribution(double __p = 0.5) bernoulli_distribution(double __p)
: _M_param(__p) : _M_param(__p)
{ } { }
...@@ -3739,10 +3773,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3739,10 +3773,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
bool _M_easy; bool _M_easy;
}; };
// constructors and member function // constructors and member functions
binomial_distribution() : binomial_distribution(1) { }
explicit explicit
binomial_distribution(_IntType __t = _IntType(1), binomial_distribution(_IntType __t, double __p = 0.5)
double __p = 0.5)
: _M_param(__t, __p), _M_nd() : _M_param(__t, __p), _M_nd()
{ } { }
...@@ -3964,9 +4000,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3964,9 +4000,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
double _M_log_1_p; double _M_log_1_p;
}; };
// constructors and member function // constructors and member functions
geometric_distribution() : geometric_distribution(0.5) { }
explicit explicit
geometric_distribution(double __p = 0.5) geometric_distribution(double __p)
: _M_param(__p) : _M_param(__p)
{ } { }
...@@ -4166,8 +4205,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -4166,8 +4205,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
double _M_p; double _M_p;
}; };
negative_binomial_distribution() : negative_binomial_distribution(1) { }
explicit explicit
negative_binomial_distribution(_IntType __k = 1, double __p = 0.5) negative_binomial_distribution(_IntType __k, double __p = 0.5)
: _M_param(__k, __p), _M_gd(__k, (1.0 - __p) / __p) : _M_param(__k, __p), _M_gd(__k, (1.0 - __p) / __p)
{ } { }
...@@ -4399,9 +4440,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -4399,9 +4440,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#endif #endif
}; };
// constructors and member function // constructors and member functions
poisson_distribution() : poisson_distribution(1.0) { }
explicit explicit
poisson_distribution(double __mean = 1.0) poisson_distribution(double __mean)
: _M_param(__mean), _M_nd() : _M_param(__mean), _M_nd()
{ } { }
...@@ -4612,10 +4656,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -4612,10 +4656,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
public: public:
/** /**
* @brief Constructs an exponential distribution with inverse scale * @brief Constructs an exponential distribution with inverse scale
* parameter 1.0
*/
exponential_distribution() : exponential_distribution(1.0) { }
/**
* @brief Constructs an exponential distribution with inverse scale
* parameter @f$\lambda@f$. * parameter @f$\lambda@f$.
*/ */
explicit explicit
exponential_distribution(const result_type& __lambda = result_type(1)) exponential_distribution(_RealType __lambda)
: _M_param(__lambda) : _M_param(__lambda)
{ } { }
...@@ -4820,9 +4870,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -4820,9 +4870,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_b; _RealType _M_b;
}; };
weibull_distribution() : weibull_distribution(1.0) { }
explicit explicit
weibull_distribution(_RealType __a = _RealType(1), weibull_distribution(_RealType __a, _RealType __b = _RealType(1))
_RealType __b = _RealType(1))
: _M_param(__a, __b) : _M_param(__a, __b)
{ } { }
...@@ -5028,9 +5079,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -5028,9 +5079,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_b; _RealType _M_b;
}; };
extreme_value_distribution() : extreme_value_distribution(0.0) { }
explicit explicit
extreme_value_distribution(_RealType __a = _RealType(0), extreme_value_distribution(_RealType __a, _RealType __b = _RealType(1))
_RealType __b = _RealType(1))
: _M_param(__a, __b) : _M_param(__a, __b)
{ } { }
...@@ -5496,7 +5548,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -5496,7 +5548,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
std::vector<double> _M_cp; std::vector<double> _M_cp;
}; };
explicit
piecewise_constant_distribution() piecewise_constant_distribution()
: _M_param() : _M_param()
{ } { }
...@@ -5769,7 +5820,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -5769,7 +5820,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
std::vector<double> _M_m; std::vector<double> _M_m;
}; };
explicit
piecewise_linear_distribution() piecewise_linear_distribution()
: _M_param() : _M_param()
{ } { }
......
...@@ -101,8 +101,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -101,8 +101,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructs a uniform distribution object. * @brief Constructs a uniform distribution object.
*/ */
uniform_int_distribution() : uniform_int_distribution(0) { }
/**
* @brief Constructs a uniform distribution object.
*/
explicit explicit
uniform_int_distribution(_IntType __a = 0, uniform_int_distribution(_IntType __a,
_IntType __b = std::numeric_limits<_IntType>::max()) _IntType __b = std::numeric_limits<_IntType>::max())
: _M_param(__a, __b) : _M_param(__a, __b)
{ } { }
......
...@@ -96,9 +96,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -96,9 +96,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/ sizeof(result_type)); / sizeof(result_type));
static constexpr result_type default_seed = 5489u; static constexpr result_type default_seed = 5489u;
// constructors and member function // constructors and member functions
simd_fast_mersenne_twister_engine()
: simd_fast_mersenne_twister_engine(default_seed)
{ }
explicit explicit
simd_fast_mersenne_twister_engine(result_type __sd = default_seed) simd_fast_mersenne_twister_engine(result_type __sd)
{ seed(__sd); } { seed(__sd); }
template<typename _Sseq, typename = _If_seed_seq<_Sseq>> template<typename _Sseq, typename = _If_seed_seq<_Sseq>>
...@@ -454,12 +459,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -454,12 +459,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}; };
public: public:
beta_distribution() : beta_distribution(1.0) { }
/** /**
* @brief Constructs a beta distribution with parameters * @brief Constructs a beta distribution with parameters
* @f$\alpha@f$ and @f$\beta@f$. * @f$\alpha@f$ and @f$\beta@f$.
*/ */
explicit explicit
beta_distribution(_RealType __alpha_val = _RealType(1), beta_distribution(_RealType __alpha_val,
_RealType __beta_val = _RealType(1)) _RealType __beta_val = _RealType(1))
: _M_param(__alpha_val, __beta_val) : _M_param(__alpha_val, __beta_val)
{ } { }
...@@ -998,9 +1005,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -998,9 +1005,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* @{
*/ */
rice_distribution() : rice_distribution(0) { }
explicit explicit
rice_distribution(result_type __nu_val = result_type(0), rice_distribution(result_type __nu_val,
result_type __sigma_val = result_type(1)) result_type __sigma_val = result_type(1))
: _M_param(__nu_val, __sigma_val), : _M_param(__nu_val, __sigma_val),
_M_ndx(__nu_val, __sigma_val), _M_ndx(__nu_val, __sigma_val),
...@@ -1014,6 +1025,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1014,6 +1025,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_ndy(result_type(0), __p.sigma()) _M_ndy(result_type(0), __p.sigma())
{ } { }
// @}
/** /**
* @brief Resets the distribution state. * @brief Resets the distribution state.
*/ */
...@@ -1244,9 +1257,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1244,9 +1257,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* @{
*/ */
nakagami_distribution() : nakagami_distribution(1) { }
explicit explicit
nakagami_distribution(result_type __mu_val = result_type(1), nakagami_distribution(result_type __mu_val,
result_type __omega_val = result_type(1)) result_type __omega_val = result_type(1))
: _M_param(__mu_val, __omega_val), : _M_param(__mu_val, __omega_val),
_M_gd(__mu_val, __omega_val / __mu_val) _M_gd(__mu_val, __omega_val / __mu_val)
...@@ -1258,6 +1275,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1258,6 +1275,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_gd(__p.mu(), __p.omega() / __p.mu()) _M_gd(__p.mu(), __p.omega() / __p.mu())
{ } { }
// @}
/** /**
* @brief Resets the distribution state. * @brief Resets the distribution state.
*/ */
...@@ -1481,9 +1500,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1481,9 +1500,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* @{
*/ */
pareto_distribution() : pareto_distribution(1) { }
explicit explicit
pareto_distribution(result_type __alpha_val = result_type(1), pareto_distribution(result_type __alpha_val,
result_type __mu_val = result_type(1)) result_type __mu_val = result_type(1))
: _M_param(__alpha_val, __mu_val), : _M_param(__alpha_val, __mu_val),
_M_ud() _M_ud()
...@@ -1495,6 +1518,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1495,6 +1518,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_ud() _M_ud()
{ } { }
// @}
/** /**
* @brief Resets the distribution state. * @brief Resets the distribution state.
*/ */
...@@ -1731,9 +1756,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1731,9 +1756,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* @{
*/ */
k_distribution() : k_distribution(1) { }
explicit explicit
k_distribution(result_type __lambda_val = result_type(1), k_distribution(result_type __lambda_val,
result_type __mu_val = result_type(1), result_type __mu_val = result_type(1),
result_type __nu_val = result_type(1)) result_type __nu_val = result_type(1))
: _M_param(__lambda_val, __mu_val, __nu_val), : _M_param(__lambda_val, __mu_val, __nu_val),
...@@ -1748,6 +1777,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1748,6 +1777,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_M_gd2(__p.nu(), __p.mu() / __p.nu()) _M_gd2(__p.nu(), __p.mu() / __p.nu())
{ } { }
// @}
/** /**
* @brief Resets the distribution state. * @brief Resets the distribution state.
*/ */
...@@ -1965,10 +1996,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1965,10 +1996,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* :{
*/ */
arcsine_distribution() : arcsine_distribution(0) { }
explicit explicit
arcsine_distribution(result_type __a = result_type(0), arcsine_distribution(result_type __a, result_type __b = result_type(1))
result_type __b = result_type(1))
: _M_param(__a, __b), : _M_param(__a, __b),
_M_ud(-1.5707963267948966192313216916397514L, _M_ud(-1.5707963267948966192313216916397514L,
+1.5707963267948966192313216916397514L) +1.5707963267948966192313216916397514L)
...@@ -1981,6 +2015,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -1981,6 +2015,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
+1.5707963267948966192313216916397514L) +1.5707963267948966192313216916397514L)
{ } { }
// @}
/** /**
* @brief Resets the distribution state. * @brief Resets the distribution state.
*/ */
...@@ -2207,10 +2243,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2207,10 +2243,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* @{
*/ */
hoyt_distribution() : hoyt_distribution(0.5) { }
explicit explicit
hoyt_distribution(result_type __q = result_type(0.5L), hoyt_distribution(result_type __q, result_type __omega = result_type(1))
result_type __omega = result_type(1))
: _M_param(__q, __omega), : _M_param(__q, __omega),
_M_ad(result_type(0.5L) * (result_type(1) + __q * __q), _M_ad(result_type(0.5L) * (result_type(1) + __q * __q),
result_type(0.5L) * (result_type(1) + __q * __q) result_type(0.5L) * (result_type(1) + __q * __q)
...@@ -2459,12 +2498,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2459,12 +2498,14 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_f_bc_ac; _RealType _M_f_bc_ac;
}; };
triangular_distribution() : triangular_distribution(0.0) { }
/** /**
* @brief Constructs a triangle distribution with parameters * @brief Constructs a triangle distribution with parameters
* @f$ a @f$, @f$ b @f$ and @f$ c @f$. * @f$ a @f$, @f$ b @f$ and @f$ c @f$.
*/ */
explicit explicit
triangular_distribution(result_type __a = result_type(0), triangular_distribution(result_type __a,
result_type __b = result_type(0.5), result_type __b = result_type(0.5),
result_type __c = result_type(1)) result_type __c = result_type(1))
: _M_param(__a, __b, __c) : _M_param(__a, __b, __c)
...@@ -2668,6 +2709,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2668,6 +2709,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
public: public:
/** The type of the range of the distribution. */ /** The type of the range of the distribution. */
typedef _RealType result_type; typedef _RealType result_type;
/** Parameter type. */ /** Parameter type. */
struct param_type struct param_type
{ {
...@@ -2711,14 +2753,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2711,14 +2753,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_RealType _M_r; _RealType _M_r;
}; };
von_mises_distribution() : von_mises_distribution(0.0) { }
/** /**
* @brief Constructs a von Mises distribution with parameters * @brief Constructs a von Mises distribution with parameters
* @f$\mu@f$ and @f$\kappa@f$. * @f$\mu@f$ and @f$\kappa@f$.
*/ */
explicit explicit
von_mises_distribution(result_type __mu = result_type(0), von_mises_distribution(result_type __mu,
result_type __kappa = result_type(1)) result_type __kappa = result_type(1))
: _M_param(__mu, __kappa) : _M_param(__mu, __kappa)
{ } { }
explicit explicit
...@@ -2956,9 +3000,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -2956,9 +3000,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
result_type _M_n; result_type _M_n;
}; };
// constructors and member function // constructors and member functions
hypergeometric_distribution() : hypergeometric_distribution(10) { }
explicit explicit
hypergeometric_distribution(result_type __N = 10, result_type __K = 5, hypergeometric_distribution(result_type __N, result_type __K = 5,
result_type __n = 1) result_type __n = 1)
: _M_param{__N, __K, __n} : _M_param{__N, __K, __n}
{ } { }
...@@ -3209,10 +3256,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3209,10 +3256,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* @{
*/ */
logistic_distribution() : logistic_distribution(0.0) { }
explicit explicit
logistic_distribution(result_type __a = result_type(0), logistic_distribution(result_type __a, result_type __b = result_type(1))
result_type __b = result_type(1))
: _M_param(__a, __b) : _M_param(__a, __b)
{ } { }
...@@ -3221,6 +3270,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3221,6 +3270,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: _M_param(__p) : _M_param(__p)
{ } { }
// @}
/** /**
* @brief Resets the distribution state. * @brief Resets the distribution state.
*/ */
...@@ -3401,7 +3452,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3401,7 +3452,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructs a uniform on sphere distribution. * @brief Constructs a uniform on sphere distribution.
*/ */
explicit
uniform_on_sphere_distribution() uniform_on_sphere_distribution()
: _M_param(), _M_nd() : _M_param(), _M_nd()
{ } { }
...@@ -3609,9 +3659,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3609,9 +3659,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/** /**
* @brief Constructors. * @brief Constructors.
* @{
*/ */
uniform_inside_sphere_distribution()
: uniform_inside_sphere_distribution(1.0)
{ }
explicit explicit
uniform_inside_sphere_distribution(_RealType __radius = _RealType(1)) uniform_inside_sphere_distribution(_RealType __radius)
: _M_param(__radius), _M_uosd() : _M_param(__radius), _M_uosd()
{ } { }
...@@ -3620,6 +3676,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION ...@@ -3620,6 +3676,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: _M_param(__p), _M_uosd() : _M_param(__p), _M_uosd()
{ } { }
// @}
/** /**
* @brief Resets the distribution state. * @brief Resets the distribution state.
*/ */
......
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.2.1 Class template bernoulli_distribution [rand.dist.bern.bernoulli] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.3.1 Class bernoulli_distribution [rand.dist.bern.bernoulli]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -35,8 +37,15 @@ test01() ...@@ -35,8 +37,15 @@ test01()
VERIFY( u.max() == std::numeric_limits<bool>::max() ); VERIFY( u.max() == std::numeric_limits<bool>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::bernoulli_distribution>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.2.2 Class template binomial_distribution [rand.dist.bern.bin] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.3.2 Class template binomial_distribution [rand.dist.bern.bin]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -36,8 +38,15 @@ test01() ...@@ -36,8 +38,15 @@ test01()
VERIFY( u.max() == u.t() ); VERIFY( u.max() == u.t() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::binomial_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.4.4 Class template cauchy_distribution [rand.dist.norm.cauchy] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.5.4 Class template cauchy_distribution [rand.dist.norm.cauchy]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,15 @@ test01() ...@@ -37,8 +39,15 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::cauchy_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.4.3 Class template chi_squared_distribution [rand.dist.norm.chisq] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.5.3 Class template chi_squared_distribution [rand.dist.norm.chisq]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -36,8 +38,15 @@ test01() ...@@ -36,8 +38,15 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::chi_squared_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.5.1 Class template discrete_distribution [rand.dist.samp.discrete] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.6.1 Class template discrete_distribution [rand.dist.samp.discrete]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -35,8 +37,15 @@ test01() ...@@ -35,8 +37,15 @@ test01()
VERIFY( probablility[0] == 1.0 ); VERIFY( probablility[0] == 1.0 );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::discrete_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.3.2 Class template exponential_distribution [rand.dist.pois.exp] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.4.2 Class template exponential_distribution [rand.dist.pois.exp]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -36,8 +38,15 @@ test01() ...@@ -36,8 +38,15 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::exponential_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.3.5 Class template extreme_value_distribution [rand.dist.pois.extreme] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.4.5 Class template extreme_value_distribution [rand.dist.pois.extreme]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,15 @@ test01() ...@@ -37,8 +39,15 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::extreme_value_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.4.5 Class template fisher_f_distribution [rand.dist.norm.f] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.5.5 Class template fisher_f_distribution [rand.dist.norm.f]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,15 @@ test01() ...@@ -37,8 +39,15 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::fisher_f_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.3.3 Class template gamma_distribution [rand.dist.pois.gamma] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.4.3 Class template gamma_distribution [rand.dist.pois.gamma]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,15 @@ test01() ...@@ -37,8 +39,15 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::gamma_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.2.3 Class template geometric_distribution [rand.dist.bern.geo] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.3.3 Class template geometric_distribution [rand.dist.bern.geo]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -36,8 +38,16 @@ test01() ...@@ -36,8 +38,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::geometric_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.4.2 Class template lognormal_distribution [rand.dist.norm.lognormal] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.5.2 Class template lognormal_distribution [rand.dist.norm.lognormal]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,16 @@ test01() ...@@ -37,8 +39,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::lognormal_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.2.4 Class template negative_binomial_distribution [rand.dist.bern.negbin] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.3.4 Class template negative_binomial_distribution [rand.dist.bern.negbin]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,16 @@ test01() ...@@ -37,8 +39,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::negative_binomial_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.4.1 Class template normal_distribution [rand.dist.norm.normal] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.5.1 Class template normal_distribution [rand.dist.norm.normal]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,16 @@ test01() ...@@ -37,8 +39,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::normal_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.5.2 Class template piecewise_constant_distribution [rand.dist.samp.pconst] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.6.2 Class template piecewise_constant_distribution [rand.dist.samp.pconst]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -39,8 +41,16 @@ test01() ...@@ -39,8 +41,16 @@ test01()
VERIFY( density[0] == 1.0 ); VERIFY( density[0] == 1.0 );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::piecewise_constant_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.5.3 Class template piecewise_linear_distribution [rand.dist.samp.plinear] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.6.3 Class template piecewise_linear_distribution [rand.dist.samp.plinear]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -40,8 +42,16 @@ test01() ...@@ -40,8 +42,16 @@ test01()
VERIFY( density[1] == 1.0 ); VERIFY( density[1] == 1.0 );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::piecewise_linear_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.3.1 Class template poisson_distribution [rand.dist.pois.poisson] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.4.1 Class template poisson_distribution [rand.dist.pois.poisson]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -36,8 +38,16 @@ test01() ...@@ -36,8 +38,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::poisson_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.4.6 Class template student_t_distribution [rand.dist.norm.t] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.5.6 Class template student_t_distribution [rand.dist.norm.t]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -36,8 +38,16 @@ test01() ...@@ -36,8 +38,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::student_t_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,12 +20,14 @@ ...@@ -20,12 +20,14 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.1.1 Class template uniform_int_distribution [rand.dist.uni.int] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.2.1 Class template uniform_int_distribution [rand.dist.uni.int]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <limits> #include <limits>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,16 @@ test01() ...@@ -37,8 +39,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<int>::max() ); VERIFY( u.max() == std::numeric_limits<int>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::uniform_int_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.1.1 Class template uniform_real_distribution [rand.dist.uni.real] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.2.2 Class template uniform_real_distribution [rand.dist.uni.real]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -36,8 +38,16 @@ test01() ...@@ -36,8 +38,16 @@ test01()
VERIFY( u.max() == 1.0 ); VERIFY( u.max() == 1.0 );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::uniform_real_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -20,11 +20,13 @@ ...@@ -20,11 +20,13 @@
// with this library; see the file COPYING3. If not see // with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// 26.4.8.3.4 Class template weibull_distribution [rand.dist.pois.weibull] // C++11
// 26.4.2.4 Concept RandomNumberDistribution [rand.concept.dist] // 26.5.8.4.4 Class template weibull_distribution [rand.dist.pois.weibull]
// 26.5.1.6 random number distribution requirements [rand.req.dist]
#include <random> #include <random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,8 +39,16 @@ test01() ...@@ -37,8 +39,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
int main() void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<std::weibull_distribution<>>();
}
int
main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -33,9 +34,16 @@ test01() ...@@ -33,9 +34,16 @@ test01()
VERIFY( u.max() == 1.0 ); VERIFY( u.max() == 1.0 );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::arcsine_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -34,8 +35,15 @@ test01() ...@@ -34,8 +35,15 @@ test01()
VERIFY( u.max() == 1.0 ); VERIFY( u.max() == 1.0 );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::beta_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -34,9 +35,16 @@ test01() ...@@ -34,9 +35,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::hoyt_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,9 +38,16 @@ test01() ...@@ -37,9 +38,16 @@ test01()
VERIFY( u.max() == 1 ); VERIFY( u.max() == 1 );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::hypergeometric_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -38,9 +39,16 @@ test01() ...@@ -38,9 +39,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::k_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -38,9 +39,16 @@ test01() ...@@ -38,9 +39,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::logistic_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,9 +38,16 @@ test01() ...@@ -37,9 +38,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::nakagami_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -40,8 +41,15 @@ test01() ...@@ -40,8 +41,15 @@ test01()
VERIFY( u.max()[1] == std::numeric_limits<result_type::value_type>::max() ); VERIFY( u.max()[1] == std::numeric_limits<result_type::value_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::normal_mv_distribution<2>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,9 +38,16 @@ test01() ...@@ -37,9 +38,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::pareto_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -37,9 +38,16 @@ test01() ...@@ -37,9 +38,16 @@ test01()
VERIFY( u.max() == std::numeric_limits<result_type>::max() ); VERIFY( u.max() == std::numeric_limits<result_type>::max() );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::rice_distribution<>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -35,8 +36,15 @@ test01() ...@@ -35,8 +36,15 @@ test01()
VERIFY( u.max() == 1.0 ); VERIFY( u.max() == 1.0 );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::triangular_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -35,9 +36,16 @@ test01() ...@@ -35,9 +36,16 @@ test01()
__gnu_cxx::uniform_inside_sphere_distribution<5, float> u5; __gnu_cxx::uniform_inside_sphere_distribution<5, float> u5;
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::uniform_inside_sphere_distribution<2>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
// 26.5.1.6 Random number distribution requirements [rand.req.dist] // 26.5.1.6 Random number distribution requirements [rand.req.dist]
#include <ext/random> #include <ext/random>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -34,9 +35,16 @@ test01() ...@@ -34,9 +35,16 @@ test01()
__gnu_cxx::uniform_on_sphere_distribution<5, float> u5; __gnu_cxx::uniform_on_sphere_distribution<5, float> u5;
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::uniform_on_sphere_distribution<2>>();
}
int int
main() main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
#include <ext/random> #include <ext/random>
#include <testsuite_hooks.h> #include <testsuite_hooks.h>
#include <testsuite_common_types.h>
void void
test01() test01()
...@@ -34,8 +35,15 @@ test01() ...@@ -34,8 +35,15 @@ test01()
VERIFY( u.max() == __gnu_cxx::__math_constants<double>::__pi ); VERIFY( u.max() == __gnu_cxx::__math_constants<double>::__pi );
} }
void
test02()
{
__gnu_test::implicitly_default_constructible test;
test.operator()<__gnu_cxx::von_mises_distribution<>>();
}
int main() int main()
{ {
test01(); test01();
return 0; test02();
} }
...@@ -687,6 +687,26 @@ namespace __gnu_test ...@@ -687,6 +687,26 @@ namespace __gnu_test
}; };
#if __cplusplus >= 201103L #if __cplusplus >= 201103L
// Generator to test non-explicit default constructor.
struct implicitly_default_constructible
{
template<typename _Tp>
void
operator()()
{
struct _Concept
{
struct Aggregate { _Tp v; };
void __constraint()
{ Aggregate __v __attribute__((unused)) = { }; }
};
void (_Concept::*__x)() __attribute__((unused))
= &_Concept::__constraint;
}
};
// Generator to test default constructor. // Generator to test default constructor.
struct constexpr_default_constructible struct constexpr_default_constructible
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment