summaryrefslogtreecommitdiff
path: root/src/gen_lib/sail_values.lem
diff options
context:
space:
mode:
authorThomas Bauereiss2017-08-10 17:42:27 +0100
committerThomas Bauereiss2017-08-10 17:51:48 +0100
commite4fce3ffd02b69e36b42ffe3c868570c45aef986 (patch)
tree2f00e0c1bae4ef56eef4865ab4529425557e9086 /src/gen_lib/sail_values.lem
parentaf1803ece80f4e278d2ff996bf9430a6a8551164 (diff)
Add support for early return to Lem backend
Implemented using the exception monad, by throwing and catching the return value
Diffstat (limited to 'src/gen_lib/sail_values.lem')
-rw-r--r--src/gen_lib/sail_values.lem2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gen_lib/sail_values.lem b/src/gen_lib/sail_values.lem
index f1541466..b4a15432 100644
--- a/src/gen_lib/sail_values.lem
+++ b/src/gen_lib/sail_values.lem
@@ -1028,7 +1028,7 @@ let assert' b msg_opt =
| Just msg -> msg
| Nothing -> "unspecified error"
end in
- if bitU_to_bool b then () else failwith msg
+ if b then () else failwith msg
(* convert numbers unsafely to naturals *)