Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Get the code right place for per statement line numbers.
  • Loading branch information
donaldh committed May 14, 2013
1 parent de8c590 commit 40b1b76
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/vm/jvm/QAST/Compiler.nqp
Expand Up @@ -3493,12 +3493,13 @@ class QAST::CompilerJAST {
$resultchild := $n - 1;
}

if $node {
my $line := HLL::Compiler.lineof($node.orig(), $node.from(), :cache(1));
$il.append(JAST::Annotation.new( :line($line) ));
}

for @stmts {
if $_.node {
my $node := $_.node;
my $line := HLL::Compiler.lineof($node.orig(), $node.from(), :cache(1));
$il.append(JAST::Annotation.new( :line($line) ));
}

my $void := $all_void || $i != $resultchild;
if $void {
if nqp::istype($_, QAST::Want) {
Expand Down

0 comments on commit 40b1b76

Please sign in to comment.