Skip Menu |
Report information
Id: 126549
Status: new
Priority: 0/
Queue: perl6

Owner: Nobody
Requestors: lloyd.fourn [at] gmail.com
Cc:
AdminCc:

Severity: (no value)
Tag: Bug
Platform: (no value)
Patch Status: (no value)
VM: (no value)



To: rakudobug [...] perl.org
From: Lloyd Fournier <lloyd.fourn [...] gmail.com>
Date: Tue, 3 Nov 2015 22:29:00 +1100
Subject: [BUG] Importing multi in lexical scope clobbers the multi
Download (untitled) / with headers
text/plain 397b
# MultiModule.pm
multi sub foo (Str) { }

multi sub foo (Int) { }

{
    use MultiModule.pm
    &foo.candidates.elems #-> 1 (should be 2)
    foo(1); #! fail
}

===========

without the {  } it works of course.


unsophisticated opinion: The $target should be all the symbols in the lexical scope not just the pad.

LL


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

For issues related to this RT instance (aka "perlbug"), please contact perlbug-admin at perl.org