From 83483b93bac1dd63bc2d8c52341aa0a8bfbb267e Mon Sep 17 00:00:00 2001 From: aarneranta Date: Mon, 3 Oct 2022 17:04:29 +0200 Subject: [PATCH] New construct: table update. Syntax t ** { cases }. Syntactic sugar for table {cases ; vvv => t \! vvv}.t --- src/compiler/GF/Grammar/Parser.y | 1 + 1 file changed, 1 insertion(+) diff --git a/src/compiler/GF/Grammar/Parser.y b/src/compiler/GF/Grammar/Parser.y index da96f9265..7837ec015 100644 --- a/src/compiler/GF/Grammar/Parser.y +++ b/src/compiler/GF/Grammar/Parser.y @@ -430,6 +430,7 @@ Exp3 RecType xs -> RecType (xs ++ [(tupleLabel (length xs+1),$3)]) t -> RecType [(tupleLabel 1,$1), (tupleLabel 2,$3)] } | Exp3 '**' Exp4 { ExtR $1 $3 } + | Exp3 '**' '{' ListCase '}' { let v = identS "vvv" in T TRaw ($4 ++ [(PV v, S $1 (Vr v))]) } | Exp4 { $1 } Exp4 :: { Term }