Skip to content

Commit

Permalink
Fix $obj.Foo::bar in the case that Foo is lexically scoped.
Browse files Browse the repository at this point in the history
  • Loading branch information
jnthn committed May 27, 2010
1 parent 972ae69 commit 982e8e3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Perl6/Actions.pm
Expand Up @@ -1767,10 +1767,11 @@ method methodop($/) {
my @parts := Perl6::Grammar::parse_name(~$<longname>);
my $name := @parts.pop;
if +@parts {
my $scope := is_lexical(pir::join('::', @parts)) ?? 'lexical' !! 'package';
$past.unshift(PAST::Var.new(
:name(@parts.pop),
:namespace(@parts),
:scope('package')
:scope($scope)
));
$past.unshift($name);
$past.name('!dispatch_::');
Expand Down

0 comments on commit 982e8e3

Please sign in to comment.