diff options
author | Son Ho | 2022-02-23 23:36:53 +0100 |
---|---|---|
committer | Son Ho | 2022-02-23 23:36:53 +0100 |
commit | 532b43ad73a4964cd75d8548d43eb894b7f225c1 (patch) | |
tree | 485fc8c35aebd2467878dc18e3f675a9e43175a1 /src/main.ml | |
parent | e3430dcb5e944af0903b272669e6ddbb8e7d59c3 (diff) |
Start working on generating code which uses a state-error monad
Diffstat (limited to 'src/main.ml')
-rw-r--r-- | src/main.ml | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main.ml b/src/main.ml index df2d1b0c..86f15959 100644 --- a/src/main.ml +++ b/src/main.ml @@ -177,15 +177,20 @@ let () = filter_useless_monadic_calls = !filter_useless_calls; filter_useless_functions = !filter_useless_functions; add_unit_args = false; + use_state_monad = not !no_state; } in + (* Small issue: the monadic `bind` only works for the error-monad, not + * the state-error monad (there are definitions to write and piping to do) *) + assert ( + (not micro_passes_config.use_state_monad) + || micro_passes_config.unfold_monadic_let_bindings); let trans_config = { Translate.eval_config; mp_config = micro_passes_config; split_files = not !no_split_files; test_unit_functions; - use_state_monad = not !no_state; extract_decreases_clauses = not !no_decreases_clauses; extract_template_decreases_clauses = !template_decreases_clauses; } |