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

Owner: Nobody
Requestors: cpan [at] zoffix.com
Cc:
AdminCc:

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



Subject: .cando fails to locate candidates with native parameters
Download (untitled) / with headers
text/plain 937b
Using .cando, the method with native str param doesn't get found, even when using native str in the Capture: <Zoffix__> m: class Foo { method x(str $y) { say "here" } }; dd Foo.^lookup('x').cando: \(Foo, my str $ = 'x') <camelia> rakudo-moar 369f25: OUTPUT: «()␤» <Zoffix__> m: class Foo { method x(str $y) { say "here" } }; dd Foo.^lookup('x').cando: \(Foo, 'x') <camelia> rakudo-moar 369f25: OUTPUT: «()␤» Yet it can be called with and without using name str arg: <Zoffix__> m: class Foo { method x($y) { say "here" } }; dd Foo.x: 'x' <camelia> rakudo-moar 369f25: OUTPUT: «here␤Bool::True␤» <Zoffix__> m: class Foo { method x(str $y) { say "here" } }; dd Foo.x: 'x' <camelia> rakudo-moar 369f25: OUTPUT: «here␤Bool::True␤» <Zoffix__> m: class Foo { method x(str $y) { say "here" } }; dd Foo.x: my str $ = 'x' <camelia> rakudo-moar 369f25: OUTPUT: «here␤Bool::True␤»


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