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
if statements clobber @_ in Rakudo #1488
Comments
From @masak<masak> rakudo: sub A (*@_) {say @_.perl; if 1 { say @_.perl } }; A(5, 4) |
From @bbkrworks fine on Kiev build |
The RT System itself - Status changed from 'new' to 'open' |
@bbkr - Status changed from 'open' to 'resolved' |
From @kylehaThis is an automatically generated mail to inform you that tests are now available in t/spec/S06-signature/slurpy-params.t commit c35c5ea64d78fe461750068f4c03f16727f16c1a t[t/spec/S06-signature/slurpy-params.t] tests for RT #72600 if statements clobber @_ in Rakudo Inline Patchdiff --git a/t/spec/S06-signature/slurpy-params.t b/t/spec/S06-signature/slurpy-params.t
index f5d3440..86334b2 100644
--- a/t/spec/S06-signature/slurpy-params.t
+++ b/t/spec/S06-signature/slurpy-params.t
@@ -312,6 +312,17 @@ eval_dies_ok 'sub rt65324(*@x, $oops) { say $oops }',
is @c[0], 'a', 'slurpy is copy-array works fine, thank you';
}
+# RT #72600
+{
+ sub A (*@_) {
+ is @_, [5, 4], 'slurpy @_ contains proper values';
+ if 1 {
+ is @_, [5, 4], 'slurpy @_ values not clobbered by if statement';
+ }
+ };
+ A(5, 4);
+}
+
done_testing;
# vim: ft=perl6 |
Migrated from rt.perl.org#72600 (status was 'resolved')
Searchable as RT72600$
The text was updated successfully, but these errors were encountered: