Change 34087 by [EMAIL PROTECTED] on 2008/06/25 18:22:18

        Subject: [PATCH] Re: split smoke for threaded -DDEBUGGING builds
        From: Reini Urban <[EMAIL PROTECTED]>
        Date: Wed, 25 Jun 2008 17:30:08 +0200
        Message-ID: <[EMAIL PROTECTED]>
        
        Plus revert #34086

Affected files ...

... //depot/perl/dump.c#307 edit
... //depot/perl/t/op/split.t#40 edit

Differences ...

==== //depot/perl/dump.c#307 (text) ====
Index: perl/dump.c
--- perl/dump.c#306~34085~      2008-06-24 07:35:11.000000000 -0700
+++ perl/dump.c 2008-06-25 11:22:18.000000000 -0700
@@ -2002,11 +2002,13 @@
     switch (o->op_type) {
     case OP_CONST:
     case OP_HINTSEVAL:
-       /* with ITHREADS, consts are stored in the pad, and the right pad
+       /* With ITHREADS, consts are stored in the pad, and the right pad
         * may not be active here, so check.
-        * (((SVOP*)o)->op_sv ? ((SVOP*)o)->op_sv : 
((my_perl->Icurpad)[(o)->op_targ])) 
+        * Looks like only during compiling the pads are illegal.
         */
-       if (((SVOP*)o)->op_sv)
+#ifdef USE_ITHREADS
+       if ((((SVOP*)o)->op_sv) || !IN_PERL_COMPILETIME)
+#endif
            PerlIO_printf(Perl_debug_log, "(%s)", SvPEEK(cSVOPo_sv));
        break;
     case OP_GVSV:

==== //depot/perl/t/op/split.t#40 (xtext) ====
Index: perl/t/op/split.t
--- perl/t/op/split.t#39~34086~ 2008-06-25 06:14:08.000000000 -0700
+++ perl/t/op/split.t   2008-06-25 11:22:18.000000000 -0700
@@ -6,8 +6,6 @@
     require './test.pl';
 }
 
-use Config;
-
 plan tests => 135;
 
 $FS = ':';
@@ -52,15 +50,8 @@
 is($_ , '1:2:3:4:5:6:::');
 
 # Does assignment to a list imply split to one more field than that?
-SKIP: {
-    if ($Config{useithreads}) {
-       skip("No IV value dump with threads", 1);
-    }
-    else {
-       $foo = runperl( switches => ['-Dt'], stderr => 1, prog => 
'($a,$b)=split;' );
-       ok($foo =~ /DEBUGGING/ || $foo =~ /const\n?\Q(IV(3))\E/);
-    }
-}
+$foo = runperl( switches => ['-Dt'], stderr => 1, prog => '($a,$b)=split;' );
+ok($foo =~ /DEBUGGING/ || $foo =~ /const\n?\Q(IV(3))\E/);
 
 # Can we say how many fields to split to when assigning to a list?
 ($a,$b) = split(' ','1 2 3 4 5 6', 2);
End of Patch.

Reply via email to