diff --git a/src/NQP/Actions.pm b/src/NQP/Actions.pm index 3b4d578..53b72bc 100644 --- a/src/NQP/Actions.pm +++ b/src/NQP/Actions.pm @@ -269,6 +269,7 @@ method statement_mod_loop:sym($/) { make $.ast; } ## Terms method term:sym($/) { make $.ast; } +method term:sym($/) { make $.ast; } method term:sym($/) { make $.ast; } method term:sym($/) { make $.ast; } method term:sym($/) { make $.ast; } @@ -284,6 +285,12 @@ method fatarrow($/) { make $past; } +method fatarrow2($/) { + my $past := $.ast; + $past.named( $.ast ); + make $past; +} + method colonpair($/) { my $past := $ ?? $[0].ast diff --git a/src/NQP/Grammar.pm b/src/NQP/Grammar.pm index 92def32..e64ae6c 100644 --- a/src/NQP/Grammar.pm +++ b/src/NQP/Grammar.pm @@ -214,6 +214,7 @@ token statement_mod_loop:sym { :s } ## Terms token term:sym { } +token term:sym { } token term:sym { } token term:sym { } token term:sym { } @@ -227,6 +228,10 @@ token fatarrow { \h* '=>' <.ws> } +token fatarrow2 { + \h* '=>' <.ws> +} + token colonpair { ':' [