# New Ticket Created by  Itsuki Toyota 
# Please include the string:  [perl #131498]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=131498 >


See the following codes and results:

$ perl6 -e 'class A { multi method f(:$vert!, Code :&c = {;}){}; multi method 
f(:$func!, Code :&c = {;}){}; }; my $a = A.new; $a.f(:func(10));'
Cannot resolve caller f(A: :func(Int)); none of these signatures match:
    (A $: :$vert!, Code :&c = { ... }, *%_)
    (A $: :$func!, Code :&c = { ... }, *%_)
  in block <unit> at -e line 1


$ perl6 -e 'class A { multi method f(:$vert!, :&c = {;}){}; multi method 
f(:$func!, :&c = {;}){
}; }; my $a = A.new; $a.f(:func(10));' # works


I think the 1st example should work same as the 2nd example.


$ perl6 --version
This is Rakudo version 2017.05-315-g160de7e built on MoarVM version 
2017.05-25-g62bc54e
implementing Perl 6.c.

Reply via email to