Skip to content

Commit

Permalink
Enforce a single prefix type constraint on parameters.
Browse files Browse the repository at this point in the history
  • Loading branch information
jnthn committed Apr 9, 2009
1 parent b512bdc commit 9854f25
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/parser/actions.pm
Expand Up @@ -2178,6 +2178,9 @@ method variable($/, $key) {
if $<sigil> eq '&' {
my $sym := outer_symbol($varname);
$var.scope( ($sym && $sym<scope>) || 'package');
if $var.scope() eq 'package' {
$var.viviself(PAST::Op.new( :pasttype('call'), :name('undef') ));
}
}

# The ! twigil always implies attribute scope.
Expand Down

0 comments on commit 9854f25

Please sign in to comment.