From fdc62b5ebc535693054364478981aae9c86572de Mon Sep 17 00:00:00 2001 From: Galfour Date: Wed, 24 Apr 2019 18:46:11 +0000 Subject: [PATCH] add leading VBAR to sum types in pascaligo --- src/ligo/parser/pascaligo/Parser.mly | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ligo/parser/pascaligo/Parser.mly b/src/ligo/parser/pascaligo/Parser.mly index 0d3136815..a5d1a4a94 100644 --- a/src/ligo/parser/pascaligo/Parser.mly +++ b/src/ligo/parser/pascaligo/Parser.mly @@ -206,9 +206,9 @@ type_tuple: par(nsepseq(type_expr,COMMA)) { $1 } sum_type: - nsepseq(variant,VBAR) { - let region = nsepseq_to_region (fun x -> x.region) $1 - in {region; value = $1} } + option(VBAR) nsepseq(variant,VBAR) { + let region = nsepseq_to_region (fun x -> x.region) $2 + in {region; value = $2} } variant: Constr Of cartesian {