Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
monolith
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
POTTIER Francois
monolith
Commits
548202c6
Commit
548202c6
authored
1 month ago
by
POTTIER Francois
Browse files
Options
Downloads
Patches
Plain Diff
Refactoring: distinguish [main_random_loop] and [main_random].
parent
82201f27
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/Engine.ml
+10
-4
10 additions, 4 deletions
src/Engine.ml
with
10 additions
and
4 deletions
src/Engine.ml
+
10
−
4
View file @
548202c6
...
@@ -1419,8 +1419,8 @@ let log scenario fuel =
...
@@ -1419,8 +1419,8 @@ let log scenario fuel =
(* -------------------------------------------------------------------------- *)
(* -------------------------------------------------------------------------- *)
(* [main_random source prologue fuel] performs an unbounded number of
test
(* [main_random
_loop
source prologue fuel] performs an unbounded number of
runs in random mode. *)
test
runs in random mode. *)
(* While the tests run, we print information roughly every second. We print
(* While the tests run, we print information roughly every second. We print
how many tests have been performed so far, our overall average speed, and
how many tests have been performed so far, our overall average speed, and
...
@@ -1437,7 +1437,7 @@ let log scenario fuel =
...
@@ -1437,7 +1437,7 @@ let log scenario fuel =
the parameter [source], is opened just once, as it would be pointless to
the parameter [source], is opened just once, as it would be pointless to
close it and reopen it many times. *)
close it and reopen it many times. *)
let
rec
main_random
source
prologue
fuel
=
let
rec
main_random
_loop
source
prologue
fuel
=
try
try
assert
(
source
=
None
);
assert
(
source
=
None
);
Gen
.
with_source
source
begin
fun
()
->
Gen
.
with_source
source
begin
fun
()
->
...
@@ -1457,7 +1457,13 @@ let rec main_random source prologue fuel =
...
@@ -1457,7 +1457,13 @@ let rec main_random source prologue fuel =
fuel. Try again, with this amount. This restricts our search
fuel. Try again, with this amount. This restricts our search
space, and (with luck) we might now be able to find an even
space, and (with luck) we might now be able to find an even
shorter scenario. *)
shorter scenario. *)
main_random
source
prologue
fuel
main_random_loop
source
prologue
fuel
(* [main_random source prologue fuel] performs an unbounded number of test
runs in random mode. *)
let
main_random
source
prologue
fuel
=
main_random_loop
source
prologue
fuel
(* -------------------------------------------------------------------------- *)
(* -------------------------------------------------------------------------- *)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment