When compiling the validation exe with msvc and run it, the msvc runtime will complain about invalid min and max arguments for uniform_real, comes from random header when init uniform distribution:
void _Init(_Ty _Min0, _Ty _Max0) noexcept { // set internal state
_STL_ASSERT(_Min0 <= _Max0 && (0 <= _Min0 || _Max0 <= _Min0 + (numeric_limits<_Ty>::max)()),
"invalid min and max arguments for uniform_real");
_Min = _Min0;
_Max = _Max0;
}
Looking closely, I found that the template arg for std::uniform_int_distribution may be wrong and thus the uint32_t's max exceeds int's limit, so MSVC decides to assert it. Clang doesn't have this crash problem but I think it's a bug anyway.
Hi thanks for the new dep_chains lab !
When compiling the validation exe with msvc and run it, the msvc runtime will complain about
invalid min and max arguments for uniform_real
, comes fromrandom
header when init uniform distribution:Looking closely, I found that the template arg for
std::uniform_int_distribution
may be wrong and thus the uint32_t's max exceeds int's limit, so MSVC decides to assert it. Clang doesn't have this crash problem but I think it's a bug anyway.