summaryrefslogtreecommitdiff
path: root/abseil-cpp/absl/random/uniform_real_distribution.h
diff options
context:
space:
mode:
Diffstat (limited to 'abseil-cpp/absl/random/uniform_real_distribution.h')
-rw-r--r--abseil-cpp/absl/random/uniform_real_distribution.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/abseil-cpp/absl/random/uniform_real_distribution.h b/abseil-cpp/absl/random/uniform_real_distribution.h
index 5ba17b2..1968334 100644
--- a/abseil-cpp/absl/random/uniform_real_distribution.h
+++ b/abseil-cpp/absl/random/uniform_real_distribution.h
@@ -73,12 +73,12 @@ class uniform_real_distribution {
: lo_(lo), hi_(hi), range_(hi - lo) {
// [rand.dist.uni.real] preconditions 2 & 3
assert(lo <= hi);
+
// NOTE: For integral types, we can promote the range to an unsigned type,
// which gives full width of the range. However for real (fp) types, this
// is not possible, so value generation cannot use the full range of the
// real type.
assert(range_ <= (std::numeric_limits<result_type>::max)());
- assert(std::isfinite(range_));
}
result_type a() const { return lo_; }