Skip to content

Commit

Permalink
remove auto-adding of *%_ in methods
Browse files Browse the repository at this point in the history
  • Loading branch information
Carl Masak committed Jun 30, 2015
1 parent 7b5256b commit dd67e25
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions src/Perl6/World.nqp
Expand Up @@ -1513,7 +1513,6 @@ class Perl6::World is HLL::World {
# object wrapping them.
method create_signature_and_params($/, %signature_info, $lexpad, $default_type_name,
:$no_attr_check, :$rw, :$method, :$invocant_type) {
# If it's a method, add auto-slurpy.
my @params := %signature_info<parameters>;
if $method {
unless @params[0]<is_invocant> {
Expand All @@ -1523,19 +1522,6 @@ class Perl6::World is HLL::World {
is_multi_invocant => 1
));
}
unless @params[+@params - 1]<named_slurpy> || @params[+@params - 1]<is_capture> {
unless nqp::can($*PACKAGE.HOW, 'hidden') && $*PACKAGE.HOW.hidden($*PACKAGE) {
@params.push(hash(
variable_name => '%_',
nominal_type => self.find_symbol(['Mu']),
named_slurpy => 1,
is_multi_invocant => 1,
sigil => '%'
));
$lexpad[0].unshift(QAST::Var.new( :name('%_'), :scope('lexical'), :decl('var') ));
$lexpad.symbol('%_', :scope('lexical'));
}
}
}

# Walk parameters, setting up parameter objects.
Expand Down

0 comments on commit dd67e25

Please sign in to comment.