Ensure that the right error is called when using the wild pattern incorrectly.

This commit is contained in:
Sander Spies 2020-04-12 14:57:39 +02:00
parent 3359848565
commit 6f0fb02bf6

View File

@ -140,7 +140,7 @@ let parse (module IO : IO) parser =
| exception SyntaxError.Error (SyntaxError.WrongFunctionArguments expr) -> | exception SyntaxError.Error (SyntaxError.WrongFunctionArguments expr) ->
Trace.fail @@ Errors.wrong_function_arguments expr Trace.fail @@ Errors.wrong_function_arguments expr
| exception SyntaxError.Error (SyntaxError.InvalidWild expr) -> | exception SyntaxError.Error (SyntaxError.InvalidWild expr) ->
Trace.fail @@ Errors.wrong_function_arguments expr Trace.fail @@ Errors.invalid_wild expr
let parse_file (source: string) = let parse_file (source: string) =
let module IO = let module IO =