summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSon Ho2022-01-28 11:07:57 +0100
committerSon Ho2022-01-28 11:07:57 +0100
commit4211b52f1dc9dd55512192ff3519d4f58c897963 (patch)
tree14f55da3732fe630c208304a5f59d07b1eaeb1e9
parentd00dd80b8b752a17c2027d6daccf74974ebf4292 (diff)
Make minor modifications
-rw-r--r--src/PureMicroPasses.ml9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/PureMicroPasses.ml b/src/PureMicroPasses.ml
index 985d9ecc..4ee67011 100644
--- a/src/PureMicroPasses.ml
+++ b/src/PureMicroPasses.ml
@@ -268,6 +268,11 @@ let filter_unused_assignments (def : fun_def) : fun_def =
(* TODO *)
def
+(** Add unit arguments for functions with no arguments *)
+let add_unit_arguments (def : fun_def) : fun_def =
+ (* TODO *)
+ def
+
(** Apply all the micro-passes to a function.
[ctx]: used only for printing.
@@ -307,7 +312,9 @@ let apply_passes_to_def (ctx : trans_ctx) (def : fun_def) : fun_def =
(* TODO: deconstruct the monadic bindings into matches *)
- (* TODO: add unit arguments for functions with no arguments *)
+ (* Add unit arguments for functions with no arguments *)
+ let def = add_unit_arguments def in
+ log#ldebug (lazy ("add_unit_arguments:\n" ^ fun_def_to_string ctx def));
(* We are done *)
def