Skip to content

Commit

Permalink
Switch add_variant to get closures instead of static code object.
Browse files Browse the repository at this point in the history
  • Loading branch information
pmichaud committed Jul 4, 2010
1 parent 77ca4f5 commit 0afa4ad
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Perl6/Compiler/Role.pm
Expand Up @@ -140,7 +140,7 @@ method finish($block) {
PAST::Op.new(
:pasttype('callmethod'), :name('!add_variant'),
PAST::Var.new( :name('master_role'), :scope('register') ),
Perl6::Actions::block_code($block, 'Sub', 1)
Perl6::Actions::block_closure(Perl6::Actions::blockref($block), 'Sub', 1)
)
);

Expand Down Expand Up @@ -190,7 +190,7 @@ method finish($block) {
),
PAST::Op.new( :pasttype('callmethod'), :name('!add_variant'),
PAST::Var.new( :name('tmp_role'), :scope('register') ),
Perl6::Actions::create_code_object($block, 'Sub', 1)
Perl6::Actions::block_closure($block, 'Sub', 1)
),
PAST::Var.new( :name('tmp_role'), :scope('register') )
);
Expand Down

0 comments on commit 0afa4ad

Please sign in to comment.