Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Tighten up what we admit for inlining; require that the arguments are…
… *all* mentioned.
  • Loading branch information
jnthn committed Oct 5, 2011
1 parent 5b40d01 commit a47b0cd
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/Perl6/Actions.pm
Expand Up @@ -1566,6 +1566,13 @@ class Perl6::Actions is HLL::Actions {
}
};
my $inline_info := $node_walker($stmt);

# Ensure we used all arguments.
for %arg_used {
if $_.value == 0 {
return 0;
}
}

# Attach inlining information.
$*ST.apply_trait('&trait_mod:<is>', $code,
Expand Down

0 comments on commit a47b0cd

Please sign in to comment.