ocaml-qcheck/0002-rm-needless-.Gen.patch

26 lines
766 B
Diff
Raw Permalink Normal View History

From 7616e43b4d011ef90e7e20f47e9837c660d8428f Mon Sep 17 00:00:00 2001
From: Jan Midtgaard <jmid@mmmi.sdu.dk>
Date: Thu, 12 Nov 2020 12:47:28 +0100
Subject: [PATCH 2/2] rm needless .Gen
---
src/core/QCheck.ml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/core/QCheck.ml b/src/core/QCheck.ml
index 67d6e3a..f05f73c 100644
--- a/src/core/QCheck.ml
+++ b/src/core/QCheck.ml
@@ -172,7 +172,7 @@ module Gen = struct
fun st ->
let f_a = float_of_int a in
let ratio = (-.f_a) /. (1. +. float_of_int b -. f_a) in
- if Random.State.float st 1. <= ratio then - (Gen.int_bound (- (a+1)) st) - 1
+ if Random.State.float st 1. <= ratio then - (int_bound (- (a+1)) st) - 1
else int_bound b st
)
--
2.28.0