Open p6rt opened 10 years ago
\
Code inlined for great justice:
role Zero { constant count = 0; } role Suc[::N] { constant count = 1 + N::count; }
subset _0 of Zero; subset _1 of Suc[Zero]; subset _2 of Suc[_1]; # and on and on ...
say Suc[Suc[Suc[Zero]]]::count;
\
It does make sense to :: into a type capture, as Ven's bigger example shows. But it seems it's done "too soon", and it blows up some sensitive internal bit or other.
The segfaults are mostly gone. Only on parrot there is a Null PMC Access, but only for two of the four examples. With said two examples there is an (non segfaulting) error on Moar and JVM as well:
$ perl6 -e 'role S[::N] { N::x }' ## no error on Moar, Parrot and JVM
$ perl6 -e 'sub foo(::N) { N::x }' ## no error on Moar, Parrot and JVM
$ perl6-m -e 'my (::N); N::x'
Cannot call method 'at_key' on a null object
in block \
$ perl6-j -e 'my (::N); N::x'
Can not call method 'at_key' on a null object
in block \
$ perl6-p -e 'my (::N); N::x'
Null PMC access in find_method('at_key')
in block \
$ cat 122716.pl6 role Zero { constant count = 0; } role Suc[::N] { constant count = 1 + N::count; } subset _0 of Zero; subset _1 of Suc[Zero]; subset _2 of Suc[_1]; say Suc[Suc[Suc[Zero]]]::count;
$ perl6-m 122716.pl6 ===SORRY!=== Cannot call method 'at_key' on a null object
$ perl6-j 122716.pl6 ===SORRY!=== Can not call method 'at_key' on a null object
$ perl6-p 122716.pl6 ===SORRY!=== Null PMC access in find_method('at_key')
The segfaults are mostly gone. Only on parrot there is a Null PMC Access, but only for two of the four examples. With said two examples there is an (non segfaulting) error on Moar and JVM as well:
$ perl6 -e 'role S[::N] { N::x }' ## no error on Moar, Parrot and JVM
$ perl6 -e 'sub foo(::N) { N::x }' ## no error on Moar, Parrot and JVM
$ perl6-m -e 'my (::N); N::x'
Cannot call method 'at_key' on a null object
in block \
$ perl6-j -e 'my (::N); N::x'
Can not call method 'at_key' on a null object
in block \
$ perl6-p -e 'my (::N); N::x'
Null PMC access in find_method('at_key')
in block \
$ cat 122716.pl6 role Zero { constant count = 0; } role Suc[::N] { constant count = 1 + N::count; } subset _0 of Zero; subset _1 of Suc[Zero]; subset _2 of Suc[_1]; say Suc[Suc[Suc[Zero]]]::count;
$ perl6-m 122716.pl6 ===SORRY!=== Cannot call method 'at_key' on a null object
$ perl6-j 122716.pl6 ===SORRY!=== Can not call method 'at_key' on a null object
$ perl6-p 122716.pl6 ===SORRY!=== Null PMC access in find_method('at_key')
@usev6 - Status changed from 'new' to 'open'
On Sat Jan 24 14:17:53 2015, bartolin@gmx.de wrote:
The segfaults are mostly gone. Only on parrot there is a Null PMC Access, but only for two of the four examples. With said two examples there is an (non segfaulting) error on Moar and JVM as well:
$ perl6 -e 'role S[::N] { N::x }' ## no error on Moar, Parrot and JVM
$ perl6 -e 'sub foo(::N) { N::x }' ## no error on Moar, Parrot and JVM
$ perl6-m -e 'my (::N); N::x' Cannot call method 'at_key' on a null object in block \
at -e:1 $ perl6-j -e 'my (::N); N::x' Can not call method 'at_key' on a null object in block \
at -e:1 $ perl6-p -e 'my (::N); N::x' Null PMC access in find_method('at_key') in block \
at -e:1 $ cat 122716.pl6 role Zero { constant count = 0; } role Suc[::N] { constant count = 1 + N::count; } subset _0 of Zero; subset _1 of Suc[Zero]; subset _2 of Suc[_1]; say Suc[Suc[Suc[Zero]]]::count;
$ perl6-m 122716.pl6 ===SORRY!=== Cannot call method 'at_key' on a null object
$ perl6-j 122716.pl6 ===SORRY!=== Can not call method 'at_key' on a null object
$ perl6-p 122716.pl6 ===SORRY!=== Null PMC access in find_method('at_key')
With the segfaults gone, this bug report is closable. (For extra points, try to make sure that the failure mode is correct, but that's not mandatory to close the ticket.)
-- Will "Coke" Coleda
Migrated from rt.perl.org#122716 (status was 'open')
Searchable as RT122716$