Skip to content

Commit 126bf84

Browse files
committed
t/op/signatures.t: Nuke the tests of modifying @_ during signature argument processing
The specific behaviour of this obscure modification case is not documented or relied upon elsewhere in code. Rather than attempt to preserve this cornercase, it's easier just to no longer test for it, as upcoming changes will alter the values that are visible.
1 parent 9b70b54 commit 126bf84

File tree

1 file changed

+2
-38
lines changed

1 file changed

+2
-38
lines changed

t/op/signatures.t

Lines changed: 2 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1399,20 +1399,8 @@ is scalar(t145()), undef;
13991399
}
14001400
is ref(t149()), "ARRAY", "t149: closure can make new lexical a ref";
14011401

1402-
# Quiet the 'use of @_ is experimental' warnings
1403-
no warnings 'experimental::args_array_with_signatures';
1404-
1405-
sub t150 ($a = do {@_ = qw(a b c); 1}, $b = 2) {
1406-
is $a, 1, "t150: a: growing \@_";
1407-
is $b, "b", "t150: b: growing \@_";
1408-
}
1409-
t150();
1410-
1411-
sub t151 ($a = do {tie @_, 'Tie::StdArray'; @_ = qw(a b c); 1}, $b = 2) {
1412-
is $a, 1, "t151: a: tied \@_";
1413-
is $b, "b", "t151: b: tied \@_";
1414-
}
1415-
t151();
1402+
# Tests t150, t151, t156 to t159 were related to modifying @_ during
1403+
# signature handling. This is no longer supported
14161404

14171405
sub t152 ($a = t152x(), @b) {
14181406
sub t152x { @b = qw(a b c); 1 }
@@ -1438,30 +1426,6 @@ is scalar(t145()), undef;
14381426
}
14391427
is t155(), "1-", "t155: closure can make new lexical hash tied";
14401428

1441-
sub t156 ($a = do {@_ = qw(a b c); 1}, @b) {
1442-
is $a, 1, "t156: a: growing \@_";
1443-
is "@b", "b c", "t156: b: growing \@_";
1444-
}
1445-
t156();
1446-
1447-
sub t157 ($a = do {@_ = qw(a b c); 1}, %b) {
1448-
is $a, 1, "t157: a: growing \@_";
1449-
is join(':', sort %b), "b:c", "t157: b: growing \@_";
1450-
}
1451-
t157();
1452-
1453-
sub t158 ($a = do {tie @_, 'Tie::StdArray'; @_ = qw(a b c); 1}, @b) {
1454-
is $a, 1, "t158: a: tied \@_";
1455-
is "@b", "b c", "t158: b: tied \@_";
1456-
}
1457-
t158();
1458-
1459-
sub t159 ($a = do {tie @_, 'Tie::StdArray'; @_ = qw(a b c); 1}, %b) {
1460-
is $a, 1, "t159: a: tied \@_";
1461-
is join(':', sort %b), "b:c", "t159: b: tied \@_";
1462-
}
1463-
t159();
1464-
14651429
# see if we can handle the equivalent of @a = ($a[1], $a[0])
14661430

14671431
sub t160 ($s, @a) {

0 commit comments

Comments
 (0)