> On 08 Jan 2015, at 10:16, Bart Wiegmans <bartwiegm...@gmail.com> wrote:
> 
> Which backend is that? I'm assuming moar.
> 
> 2015-01-08 10:14 GMT+01:00 Elizabeth Mattijsen <l...@dijkmat.nl>:
> > On 04 Oct 2014, at 02:41, (via RT) <perl6-bugs-follo...@perl.org> wrote:
> >
> > # New Ticket Created by
> > # Please include the string:  [perl #122896]
> > # in the subject line of all future correspondence about this issue.
> > # <URL: https://rt.perl.org/Ticket/Display.html?id=122896 >
> >
> >
> > Create a module M containing "module M { sub f () is cached is export { } 
> > }".  When precompiled, the following error occurs when f() is called:
> >
> > Cannot invoke null object
> >  in block  at src/gen/m-CORE.setting:3604
> >  in any enter at src/gen/m-Metamodel.nqp:3110
> >  in method invoke at src/gen/m-CORE.setting:3548
> >
> > This is perl6 version 2014.09-81-g89abcf2 built on MoarVM version 
> > 2014.09-12-gb9e24ee
> 
> At least on OS X, this has now changed to a segfault on Moar, easily 
> reproducible thus:
> 
> $ perl6 -e 'CompUnit.new("t/spec/packages/Example/C.pm").precomp’
> $ perl6 -It/spec/packages -e ‘use Example::C; f()’
> Segmentation fault: 11

I further golfed this down to:

multi sub trait_mod:<is>(Routine $r, :$foo!) {
    $r.wrap(-> |c {
    });
}
sub a is foo { say "a" };
a

Put this in a file with a .pm extension, precomp it like above, and try to load 
it.



Liz

Reply via email to