Optional vbar for ReasonLIGO sumtypes

This commit is contained in:
Sander 2020-02-04 10:39:15 +00:00
parent d2630379ec
commit fbc61eb809
3 changed files with 865 additions and 841 deletions

View File

@ -226,7 +226,7 @@ core_type:
in TApp {region; value = constr,arg} }
sum_type:
"|" nsepseq(variant,"|") {
ioption("|") nsepseq(variant,"|") {
Scoping.check_variants (Utils.nsepseq_to_list $2);
let region = nsepseq_to_region (fun x -> x.region) $2
in TSum {region; value=$2} }

File diff suppressed because it is too large Load Diff

View File

@ -3,7 +3,7 @@ type storage = int;
/* variant defining pseudo multi-entrypoint actions */
type action =
| Increment(int)
Increment(int)
| Decrement(int);
let add = ((a: int), (b: int)) => a + b;