New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Parrot resets lexicals initialized in INIT blocks #3517
Comments
From @hoelzroIf I have the following code in a module: my $foo; INIT $foo = 7; MoarVM and the JVM properly initialize $foo to 7, but Parrot clobbers that 7 after the INIT block, it seems. A test is attached. |
From @lizmatOn 12 Sep 2014, at 00:05, Rob Hoelz (via RT) <perl6-bugs-followup@perl.org> wrote:
If you remove the Test, and just have something like; my $foo; it *does* seem to work on my parakudo… So Test seems to be interfering somehow? Liz |
The RT System itself - Status changed from 'new' to 'open' |
From @hoelzroOn Thu Sep 11 15:32:28 2014, elizabeth wrote:
Yes, this only happens within a module. I haven't tried on classes/roles/etc yet. |
From @usev6I can leave of Test and reproduce the problem within a class or a module. $ perl6-p -e 'module Foo; my $foo; INIT $foo = 42; say $foo' $ perl6-p -e 'class Foo { my $foo; INIT $foo = 42; say $foo }' |
From @usev6I added two tests to S04-phasers/init.t with commit Raku/roast@8d25686f90. Those tests pass on MoarVM and JVM Since support for Parrot was suspended with Rakudo Star Release 2015.02, I'm closing this "parrot only" ticket. I'll add the ticket to a list of closed ticket living in the mu repository: https://github.com/perl6/mu/blob/master/misc/rt.perl.org/tickets_closed_parrot_only.txt. In case support for Parrot will be restored in some future release the listed tickets can be checked and re-opened as appropriate. |
@usev6 - Status changed from 'open' to 'rejected' |
Migrated from rt.perl.org#122765 (status was 'rejected')
Searchable as RT122765$
The text was updated successfully, but these errors were encountered: