mirror of
https://github.com/bolero-MURAKAMI/Sprout.git
synced 2025-07-14 15:04:09 +00:00
[破壊的変更] uniform_int_distribution::max() 9 -> numeric_limits::max()
add reset function
This commit is contained in:
parent
b60a7aca9c
commit
81603007f6
8 changed files with 19 additions and 8 deletions
|
@ -801,9 +801,9 @@ namespace sprout {
|
|||
public:
|
||||
SPROUT_CONSTEXPR param_type()
|
||||
: min_(0)
|
||||
, max_(9)
|
||||
, max_(sprout::numeric_limits<IntType>::max())
|
||||
{}
|
||||
explicit SPROUT_CONSTEXPR param_type(IntType min_arg, IntType max_arg = 9)
|
||||
explicit SPROUT_CONSTEXPR param_type(IntType min_arg, IntType max_arg = sprout::numeric_limits<IntType>::max())
|
||||
: min_((SPROUT_ASSERT(min_arg <= max_arg), min_arg))
|
||||
, max_(max_arg)
|
||||
{}
|
||||
|
@ -861,9 +861,9 @@ namespace sprout {
|
|||
public:
|
||||
SPROUT_CONSTEXPR uniform_int_distribution() SPROUT_NOEXCEPT
|
||||
: min_(0)
|
||||
, max_(9)
|
||||
, max_(sprout::numeric_limits<IntType>::max())
|
||||
{}
|
||||
explicit SPROUT_CONSTEXPR uniform_int_distribution(IntType min_arg, IntType max_arg = 9)
|
||||
explicit SPROUT_CONSTEXPR uniform_int_distribution(IntType min_arg, IntType max_arg = sprout::numeric_limits<IntType>::max())
|
||||
: min_((SPROUT_ASSERT(min_arg <= max_arg), min_arg))
|
||||
, max_(max_arg)
|
||||
{}
|
||||
|
@ -883,6 +883,7 @@ namespace sprout {
|
|||
SPROUT_CONSTEXPR result_type max() const SPROUT_NOEXCEPT {
|
||||
return max_;
|
||||
}
|
||||
SPROUT_CXX14_CONSTEXPR void reset() SPROUT_NOEXCEPT {}
|
||||
SPROUT_CONSTEXPR param_type param() const SPROUT_NOEXCEPT {
|
||||
return param_type(min_, max_);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue