Skip to content

Instantly share code, notes, and snippets.

@ShimmerFairy
Created July 11, 2010 21:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ShimmerFairy/471833 to your computer and use it in GitHub Desktop.
Save ShimmerFairy/471833 to your computer and use it in GitHub Desktop.
the token is found on line 905 of src/Perl6/Grammar.pm:
token variable_declarator {
:my $*IN_DECL := 'variable';
<variable>
{ $*IN_DECL := '' }
[
<.unsp>?
$<shape>=[
| '(' ~ ')' <signature>
| '[' ~ ']' <semilist>
| '{' ~ '}' <semilist>
]*
]?
<trait>*
<post_constraint>* #this is added
<default_value>? #this is added as well
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment