diff options
author | Son HO | 2024-04-07 15:09:58 +0200 |
---|---|---|
committer | GitHub | 2024-04-07 15:09:58 +0200 |
commit | 05164f1ea87b7da14f60e6dbcc718a4f8d639ea1 (patch) | |
tree | 7973a53f134c38a856376b6204a7c76900eaafe7 /compiler/Main.ml | |
parent | d8650bfc5c4dc78fda13953dac93c9e6c24489d1 (diff) | |
parent | a9a2f81e365eeef4fd157fb56cd5107f95c91163 (diff) |
Merge pull request #113 from AeneasVerif/escherichia/error_catching_translate
Error catching should tell when code couldn't be generated
Diffstat (limited to '')
-rw-r--r-- | compiler/Main.ml | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/Main.ml b/compiler/Main.ml index 416f3a07..6161f2f2 100644 --- a/compiler/Main.ml +++ b/compiler/Main.ml @@ -283,7 +283,9 @@ let () = if !Errors.error_list <> [] then ( List.iter (fun (meta, msg) -> log#serror (Errors.format_error_message meta msg)) - !Errors.error_list; + (* Reverse the list of error messages so that we print them from the + earliest to the latest. *) + (List.rev !Errors.error_list); exit 1); (* Print total elapsed time *) |