mirror of
https://github.com/bolero-MURAKAMI/Sprout
synced 2025-08-03 12:49:50 +00:00
エラー通知を標準例外に変更
This commit is contained in:
parent
9823888049
commit
4729d31bf2
22 changed files with 76 additions and 57 deletions
|
@ -3,6 +3,7 @@
|
|||
|
||||
#include <iosfwd>
|
||||
#include <istream>
|
||||
#include <stdexcept>
|
||||
#include <type_traits>
|
||||
#include <sprout/config.hpp>
|
||||
#include <sprout/random/detail/signed_unsigned_tools.hpp>
|
||||
|
@ -26,7 +27,7 @@ namespace sprout {
|
|||
static SPROUT_CONSTEXPR IntType arg_check(IntType min_arg, IntType max_arg) {
|
||||
return arg_check_nothrow(min_arg, max_arg)
|
||||
? min_arg
|
||||
: throw "assert(min_arg <= max_arg)"
|
||||
: throw std::invalid_argument("uniform_smallint<>: invalid argument (min_arg <= max_arg)")
|
||||
;
|
||||
}
|
||||
public:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue