From f870c4d80f9e1b55a18c54f8119e5ed11f9d14e1 Mon Sep 17 00:00:00 2001 From: krasimir Date: Thu, 18 Mar 2010 19:34:30 +0000 Subject: syntax for inaccessible patterns in GF --- src/compiler/GF/Grammar/Parser.y | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/compiler/GF/Grammar/Parser.y') diff --git a/src/compiler/GF/Grammar/Parser.y b/src/compiler/GF/Grammar/Parser.y index 2a08caa1b..f1b429339 100644 --- a/src/compiler/GF/Grammar/Parser.y +++ b/src/compiler/GF/Grammar/Parser.y @@ -35,6 +35,7 @@ import GF.Compile.Update (buildAnyTree) '$' { T_int_label } '(' { T_oparen } ')' { T_cparen } + '~' { T_tilde } '*' { T_star } '**' { T_starstar } '+' { T_plus } @@ -487,6 +488,7 @@ Patt2 | '[' String ']' { PChars $2 } | '#' Ident { PMacro $2 } | '#' Ident '.' Ident { PM $2 $4 } + | '~' Exp6 { PTilde $2 } | '_' { PW } | Ident { PV $1 } | Ident '.' Ident { PP $1 $3 [] } @@ -526,8 +528,8 @@ ListPatt | PattArg ListPatt { $1 : $2 } PattArg :: { Patt } - : Patt2 { $1 } - | '{' Patt2 '}' { PImplArg $2 } + : Patt2 { $1 } + | '{' Patt2 '}' { PImplArg $2 } Arg :: { [(BindType,Ident)] } Arg -- cgit v1.2.3