We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Migrated from rt.perl.org#131152 (status was 'new')
Searchable as RT131152$
The text was updated successfully, but these errors were encountered:
perl6 -v This is Rakudo version 2017.01 built on MoarVM version 2017.01
sub f { my $i = 0; while True { FIRST { say "FIRST: $i"}; LAST { say "LAST: $i"}; last if ++$i > 100; } }
doesn't compile: ===SORRY!=== Cannot reference undeclared local 'LOOP_BLOCK_1'
without FIRST gives an error:
sub f { my $i = 0; while True { # FIRST { say "FIRST: $i"}; LAST { say "LAST: $i"}; last if ++$i > 100; } }
f();
LAST: 0 No such method '!capture_phasers' for invocant of type 'Code' in block <unit> at t1.p6 line 16
in Promises compiles but gives random results:
await do for 1..10 { start { my $i = 0; loop { FIRST { say "FIRST: $i"}; LAST { say "LAST: $i"}; last if ++$i > 100; } } }
FIRST: 0 FIRST: 0 FIRST: 2 FIRST: 0 LAST: 0 LAST: 5 LAST: 5 FIRST: 0 FIRST: 0 FIRST: 64 LAST: 103 LAST: 103 LAST: 103 FIRST: 103 LAST: 104 FIRST: 2 FIRST: 98 LAST: 102 LAST: 102 LAST: 102
changing loop/while to for 1..* solves first two issues, but:
using for 1..* instead of loop give more stable, but still sometimes incorrect results with promises:
await do for 1..10 { start { my $i = 0; for 1..* { FIRST { say "FIRST: $i"}; LAST { say "LAST: $i"}; #say $i; last if ++$i > 100; } } }
FIRST: 0 FIRST: 0 FIRST: 77 FIRST: 0 LAST: 101 LAST: 101 LAST: 101 LAST: 101 FIRST: 0 FIRST: 0 LAST: 101 FIRST: 0 LAST: 101 FIRST: 0 LAST: 101 FIRST: 0 LAST: 101 FIRST: 0 LAST: 101 LAST: 101
Sorry, something went wrong.
No branches or pull requests
Migrated from rt.perl.org#131152 (status was 'new')
Searchable as RT131152$
The text was updated successfully, but these errors were encountered: