You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
for 1,1,2,2 -> $num, $value {
... stuff ...
loop {
earliest $channel {
more * { ... $num and $value are both still 1 even on second for loop ... }
done * { last }
}
}
}
On the second time through the surrounding for loop, inside the
earliest block, the lexical $num and $value are still the values from
the first time through the loop.
for 1,1,2,2 -> $num, $value {
... stuff ...
loop {
earliest $channel {
more * { ... $num and $value are both still 1 even on second for
loop ... }
done * { last }
}
}
}
On the second time through the surrounding for loop, inside the
earliest block, the lexical $num and $value are still the values from
the first time through the loop.
Github gist has a test case.
The earliest syntax has been removed from Perl 6, and there are plenty of examples of the react/supply/whenever syntax that replaces it and closure semantics, so will reject this one.
Migrated from rt.perl.org#126454 (status was 'rejected')
Searchable as RT126454$
The text was updated successfully, but these errors were encountered: