On Tue Apr 21 02:41:12 2009, masak wrote:
> <ihrd> rakudo: multi foo ($a, %h?) { say 1}; multi foo (@a) {say 2};
> foo(<1 2 3>)
> <p6eval> rakudo 69b318: OUTPUT«Ambiguous dispatch to multi 'foo'.
> Ambiguous candidates had signatures:␤:(Any $a, Associative.new()
> %h?)␤:(Positional.new() @a)
> <moritz_> Associative.new()? wtf/?
> <moritz_> that seems to be not a type, but an implicit default value
> <wayland76> I thought associative was a role
> <wayland76> Oh, but the .new is weird :)
> <masak> Associative.new() looks like the output of .perl
> <masak> anyway, it's rakudobuggable.
> * masak rakudobugs
> 
> It could be argued that it should simply say "Associative" and
> "Positional", not "Associative.new()" and "Positional.new()".

That would still be wrong since a :(Positional @a) means a Positional
thing of things that that do Positional. In that case :(@a) is fine. So
now (git c76d8d0) it is that, and also it shows parameterized types and
typed arrays/hashes and so forth better too.

Thanks,

Jonathan

Reply via email to