Skip to content

Commit

Permalink
Wrap single statement into PAST::Block inside if/for/while for preser…
Browse files Browse the repository at this point in the history
…ve semantic
  • Loading branch information
bacek committed Mar 2, 2011
1 parent e613f2b commit bf11a89
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion compilers/opsc/src/Ops/Compiler/Actions.pm
Expand Up @@ -598,7 +598,9 @@ method statement_control:sym<continue> ($/) {

method statement_or_block ($/) {
$<labeled_statement>
?? make $<labeled_statement>.ast
?? make PAST::Block.new(
$<labeled_statement>.ast
)
!! make $<blockoid>.ast
}

Expand Down

0 comments on commit bf11a89

Please sign in to comment.