summaryrefslogtreecommitdiff
path: root/src/constant_fold.ml
diff options
context:
space:
mode:
Diffstat (limited to 'src/constant_fold.ml')
-rw-r--r--src/constant_fold.ml2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/constant_fold.ml b/src/constant_fold.ml
index 407bd69a..0e34ed5b 100644
--- a/src/constant_fold.ml
+++ b/src/constant_fold.ml
@@ -78,6 +78,7 @@ and exp_of_value =
| V_tuple vs ->
mk_exp (E_tuple (List.map exp_of_value vs))
| V_unit -> mk_lit_exp L_unit
+ | V_attempted_read str -> mk_exp (E_id (mk_id str))
| _ -> failwith "No expression for value"
(* We want to avoid evaluating things like print statements at compile
@@ -100,6 +101,7 @@ let safe_primops =
"prerr_string";
"read_ram";
"write_ram";
+ "get_time_ns";
"Elf_loader.elf_entry";
"Elf_loader.elf_tohost"
]