From a663ea0a2df6e9bc2033812f8320178a9a51bc6b Mon Sep 17 00:00:00 2001 From: Bodigrim Date: Mon, 18 Jan 2021 18:34:33 +0000 Subject: [PATCH] Add a law about endpoints --- src/System/Random/Internal.hs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/System/Random/Internal.hs b/src/System/Random/Internal.hs index e53dc025..2b663518 100644 --- a/src/System/Random/Internal.hs +++ b/src/System/Random/Internal.hs @@ -621,6 +621,11 @@ class UniformRange a where -- -- > isInRange (x, x) y == x == y -- + -- Endpoints are endpoints: + -- + -- > isInRange (lo, hi) x ==> + -- > isInRange (lo, x) hi == x == hi + -- -- Ranges are transitive relations: -- -- > isInRange (lo, hi) lo' && isInRange (lo, hi) hi' &&