Open p6rt opened 9 years ago
$ ./perl6 -e 'sub aa (Mu:U ::T) { say T; my T $a = T; say $a.WHAT; }; aa(Int); aa(Nil)'
(Int)
(Int)
Nil
Method 'gist' not found for invocant of class 'T'
in sub aa at -e:1
in block \
I'm mystified as to how the gist method goes missing there. It seems entirely available when I'm not using a type parameter:
$ ./perl6 -e 'say Int; my Int $a = Int; say $a.WHAT; say Nil; my Nil $b = Nil; say $b.WHAT;' (Int) (Int) Nil Nil
I also don't get an error if the "= T" is omitted, which is bizarre because the variable contains the same value by default. The error doesn't occur at the time of the assignment, though: it only happens with the say statement.
-zefram
That's a nice one. Still reproducible (2017.11, HEAD(5929887))
On 2015-09-20 09:29:41, zefram@fysh.org wrote:
$ ./perl6 -e 'sub aa (Mu:U ::T) { say T; my T $a = T; say $a.WHAT; }; aa(Int); aa(Nil)' (Int) (Int) Nil Method 'gist' not found for invocant of class 'T' in sub aa at -e:1 in block \
at -e:1 I'm mystified as to how the gist method goes missing there. It seems entirely available when I'm not using a type parameter:
$ ./perl6 -e 'say Int; my Int $a = Int; say $a.WHAT; say Nil; my Nil $b = Nil; say $b.WHAT;' (Int) (Int) Nil Nil
I also don't get an error if the "= T" is omitted, which is bizarre because the variable contains the same value by default. The error doesn't occur at the time of the assignment, though: it only happens with the say statement.
-zefram
The RT System itself - Status changed from 'new' to 'open'
Migrated from rt.perl.org#126118 (status was 'open')
Searchable as RT126118$