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

Owner: Nobody
Requestors: gfldex <wenzel.peppmeyer [at] gmx.de>
Cc:
AdminCc:

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



Date: Sat, 16 Jan 2016 18:21:10 +0100 (CET)
Subject: stringyfication on type capture in signatures returns the literal of the type capture instead of the resolved type named
To: rakudobug [...] perl.org
From: "Wenzel P. P. Peppmeyer" <wenzel.peppmeyer [...] gmx.de>
Download (untitled) / with headers
text/plain 482b
class C {}; sub outer(::T $c){ sub (T){ dd &?ROUTINE.signature.params[0], T === C, T.new } }; my $inner = outer(C); $inner(C.new); # OUTPUT«T $␤Bool::True␤C.new␤» # expected: # OUTPUT«C $␤Bool::True␤C.new # The typecheck on function call does work. It's merely a stringy problem. $inner(W.new); # OUTPUT«Type check failed in binding <anon>; # expected C but got W␤ in sub at /tmp/uEPuZVCl2m line 1␤ in block # <unit> at /tmp/uEPuZVCl2m line 1␤␤»


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