summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRobert Norton2017-05-08 12:33:50 +0100
committerRobert Norton2017-05-08 15:29:55 +0100
commit3406e50f3f4acd5c3535d0e324e5e2e00ba76759 (patch)
treec7735c58609c6eaef28935c631bb72823add4629 /src
parent33a529617d6f69651241b768c9cd9d1316a66466 (diff)
add error messages for unhandled pattern match nodes in ocaml pretty printer.
Diffstat (limited to 'src')
-rw-r--r--src/pretty_print_ocaml.ml3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/pretty_print_ocaml.ml b/src/pretty_print_ocaml.ml
index 94c524c2..0ce8d782 100644
--- a/src/pretty_print_ocaml.ml
+++ b/src/pretty_print_ocaml.ml
@@ -183,6 +183,9 @@ let doc_pat_ocaml =
| _ -> non_bit_print ())
| P_tup pats -> parens (separate_map comma_sp pat pats)
| P_list pats -> brackets (separate_map semi pat pats) (*Never seen but easy in ocaml*)
+ | P_record _ -> raise (Reporting_basic.err_unreachable l "unhandled record pattern")
+ | P_vector_indexed _ -> raise (Reporting_basic.err_unreachable l "unhandled vector_indexed pattern")
+ | P_vector_concat _ -> raise (Reporting_basic.err_unreachable l "unhandled vector_concat pattern")
in pat
let doc_exp_ocaml, doc_let_ocaml =