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

Commit

Permalink
Automatically add ¢ lexical to regex blocks.
Browse files Browse the repository at this point in the history
  • Loading branch information
pmichaud committed Nov 24, 2009
1 parent a89723d commit 0ce5b09
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Regex/P6Regex/Actions.pm
Expand Up @@ -482,6 +482,10 @@ sub buildsub($rpast, $block = PAST::Block.new() ) {
:pasttype('concat'),
:capnames(%capnames)
);
unless $block.symbol('') {
$block.push( PAST::Var.new( :name<>, :scope<lexical>, :isdecl ) );
$block.symbol('', :scope<lexical> );
}
$block.push($rpast);
$block.blocktype('method');
$block;
Expand Down

0 comments on commit 0ce5b09

Please sign in to comment.