Navigation Menu

Skip to content
This repository has been archived by the owner on Feb 3, 2021. It is now read-only.

Commit

Permalink
Add single angle bracket quoting to NQP (non-splitting for the moment).
Browse files Browse the repository at this point in the history
  • Loading branch information
pmichaud committed Oct 20, 2009
1 parent 64c960f commit b917679
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/NQP/Actions.pm
Expand Up @@ -17,6 +17,8 @@ method term:sym<value>($/) { make $<value>.ast; }

method circumfix:sym<( )>($/) { make $<EXPR>.ast; }

method circumfix:sym<ang>($/) { make $<quote_EXPR>.ast; }

method postcircumfix:sym<[ ]>($/) {
make PAST::Var.new( $<EXPR>.ast , :scope('keyed_int') );
}
Expand Down
1 change: 1 addition & 0 deletions src/NQP/Grammar.pm
Expand Up @@ -22,6 +22,7 @@ token prefix:sym<--> { $<sym>=['--'] <O('%autoincrement')> }
token postfix:sym<++> { $<sym>=['++'] <O('%autoincrement')> }

token circumfix:sym<( )> { '(' <EXPR> ')' }
token circumfix:sym<ang> { <?[<]> <quote_EXPR: ':q', ':w'> }

token postcircumfix:sym<[ ]> {
'[' <EXPR> ']'
Expand Down

0 comments on commit b917679

Please sign in to comment.