Change 30185 by [EMAIL PROTECTED] on 2007/02/09 20:50:14
Tests to verify that bug 37350 isn't fixed.
Affected files ...
... //depot/maint-5.8/perl/t/op/array.t#11 edit
Differences ...
==== //depot/maint-5.8/perl/t/op/array.t#11 (xtext) ====
Index: perl/t/op/array.t
--- perl/t/op/array.t#10~30181~ 2007-02-09 09:20:56.000000000 -0800
+++ perl/t/op/array.t 2007-02-09 12:50:14.000000000 -0800
@@ -7,7 +7,7 @@
require 'test.pl';
-plan (99);
+plan (107);
#
# @foo, @bar, and @ary are also used from tie-stdarray after tie-ing them
@@ -328,5 +328,34 @@
is("$x $y $z", "1 1 2");
}
+{
+ # I don't think that it's safe to fix bug #37350 in maint
+ my @array = (1..4);
+ [EMAIL PROTECTED] = 7;
+ is ($#{4}, -1);
+ is ($#array, 7);
+
+ my $x;
+ $#{$x} = 3;
+ is(scalar @$x, 4);
+
+ push @[EMAIL PROTECTED], 23;
+ is ($array[8], 23);
+}
+{
+ # Bug #37350 -- once more with a global
+ use vars '@array';
+ @array = (1..4);
+ [EMAIL PROTECTED] = 7;
+ is ($#{4}, -1);
+ is ($#array, 7);
+
+ my $x;
+ $#{$x} = 3;
+ is(scalar @$x, 4);
+
+ push @[EMAIL PROTECTED], 23;
+ is ($array[8], 23);
+}
"We're included by lib/Tie/Array/std.t so we need to return something true";
End of Patch.