Change 33467 by [EMAIL PROTECTED] on 2008/03/10 21:34:23
Subject: [PATCH] Re: [PATCH] MAD fix p55 $[
From: Gerard Goossen <[EMAIL PROTECTED]>
Date: Mon, 10 Mar 2008 15:44:03 +0100
Message-ID: <[EMAIL PROTECTED]>
Affected files ...
... //depot/perl/mad/t/p55.t#6 edit
... //depot/perl/op.c#996 edit
Differences ...
==== //depot/perl/mad/t/p55.t#6 (text) ====
Index: perl/mad/t/p55.t
--- perl/mad/t/p55.t#5~33466~ 2008-03-10 14:30:50.000000000 -0700
+++ perl/mad/t/p55.t 2008-03-10 14:34:23.000000000 -0700
@@ -64,10 +64,6 @@
our %failing = map { $_, 1 } qw|
../t/comp/require.t
-../t/op/array.t
-../t/op/local.t
-../t/op/substr.t
-
../t/comp/parser.t
../t/op/switch.t
@@ -172,10 +168,10 @@
sub PerlIO::F_UTF8 () { 0x00008000 } # from perliol.h
BEGIN { PerlIO::Layer->find("encoding",1);}
########
-# TODO from ../t/op/array.t
+# from ../t/op/array.t
$[ = 1
########
-# TODO from t/comp/parser.t
+# from t/comp/parser.t
$x = 1 for ($[) = 0;
########
# from t/op/getppid.t
==== //depot/perl/op.c#996 (text) ====
Index: perl/op.c
--- perl/op.c#995~33369~ 2008-02-25 04:48:22.000000000 -0800
+++ perl/op.c 2008-03-10 14:34:23.000000000 -0700
@@ -4335,10 +4335,11 @@
if (PL_eval_start)
PL_eval_start = 0;
else {
- /* FIXME for MAD */
- op_free(o);
- o = newSVOP(OP_CONST, 0, newSViv(CopARYBASE_get(&PL_compiling)));
- o->op_private |= OPpCONST_ARYBASE;
+ if (!PL_madskills) { /* assignment to $[ is ignored when making a
mad dump */
+ op_free(o);
+ o = newSVOP(OP_CONST, 0,
newSViv(CopARYBASE_get(&PL_compiling)));
+ o->op_private |= OPpCONST_ARYBASE;
+ }
}
}
return o;
End of Patch.