Change 30682: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30682 by [EMAIL PROTECTED] on 2007/03/22 10:18:13

Integrate:
[ 28486]
Add constants needed for recvmsg()/sendmsg() support.

Affected files ...

... //depot/maint-5.8/perl/ext/POSIX/Makefile.PL#6 integrate

Differences ...

 //depot/maint-5.8/perl/ext/POSIX/Makefile.PL#6 (text) 
Index: perl/ext/POSIX/Makefile.PL
--- perl/ext/POSIX/Makefile.PL#5~30674~ 2007-03-21 16:14:31.0 -0700
+++ perl/ext/POSIX/Makefile.PL  2007-03-22 03:18:13.0 -0700
@@ -45,7 +45,8 @@
   IGNBRK IGNCR IGNPAR INLCR INPCK INT_MAX INT_MIN ISIG ISTRIP IXOFF IXON
   LC_ALL LC_COLLATE LC_CTYPE LC_MESSAGES LC_MONETARY LC_NUMERIC LC_TIME
   LINK_MAX LONG_MAX LONG_MIN L_ctermid L_cuserid L_tmpnam MAX_CANON
-  MAX_INPUT MB_LEN_MAX NAME_MAX NCCS NGROUPS_MAX NOFLSH OPEN_MAX OPOST
+  MAX_INPUT MB_LEN_MAX MSG_CTRUNC MSG_DONTROUTE MSG_EOR MSG_OOB MSG_PEEK 
+  MSG_TRUNC MSG_WAITALL NAME_MAX NCCS NGROUPS_MAX NOFLSH OPEN_MAX OPOST
   PARENB PARMRK PARODD PATH_MAX PIPE_BUF RAND_MAX R_OK SCHAR_MAX
   SCHAR_MIN SEEK_CUR SEEK_END SEEK_SET SHRT_MAX SHRT_MIN SIGABRT SIGALRM
   SIGCHLD SIGCONT SIGFPE SIGHUP SIGILL SIGINT SIGKILL SIGPIPE SIGQUIT
End of Patch.


Change 30679: Fix error message for re::regnames_iterinit()

2007-03-22 Thread Rafael Garcia-Suarez
Change 30679 by [EMAIL PROTECTED] on 2007/03/22 09:16:37

Fix error message for re::regnames_iterinit()

Affected files ...

... //depot/perl/universal.c#159 edit

Differences ...

 //depot/perl/universal.c#159 (text) 
Index: perl/universal.c
--- perl/universal.c#158~30678~ 2007-03-22 02:01:37.0 -0700
+++ perl/universal.c2007-03-22 02:16:37.0 -0700
@@ -1243,8 +1243,8 @@
 {
 dVAR; 
 dXSARGS;
-if (items != 0 )
-   Perl_croak(aTHX_ Usage: %s(%s), re::regnames_iterinit);
+if (items != 0)
+   Perl_croak(aTHX_ Usage: re::regnames_iterinit());
 PERL_UNUSED_VAR(cv); /* -W */
 PERL_UNUSED_VAR(ax); /* -Wall */
 SP -= items;
End of Patch.


Change 30680: regexp refcount is an integer, not a pointer

2007-03-22 Thread Rafael Garcia-Suarez
Change 30680 by [EMAIL PROTECTED] on 2007/03/22 09:19:22

regexp refcount is an integer, not a pointer

Affected files ...

... //depot/perl/dump.c#258 edit

Differences ...

 //depot/perl/dump.c#258 (text) 
Index: perl/dump.c
--- perl/dump.c#257~30678~  2007-03-22 02:01:37.0 -0700
+++ perl/dump.c 2007-03-22 02:19:22.0 -0700
@@ -1273,8 +1273,9 @@
 ( PERL_PV_PRETTY_QUOTE | PERL_PV_ESCAPE_RE | 
PERL_PV_PRETTY_ELIPSES |
 ((re-extflags  RXf_UTF8) ? PERL_PV_ESCAPE_UNI : 0))
 );
-Perl_dump_indent(aTHX_ level+1, file, PAT = %s\n, s);
-Perl_dump_indent(aTHX_ level+1, file, REFCNT = 
%IVdf\n, (IV*)re-refcnt);
+   Perl_dump_indent(aTHX_ level+1, file, PAT = %s\n, s);
+   Perl_dump_indent(aTHX_ level+1, file, REFCNT = %IVdf\n,
+   (IV)re-refcnt);
 }
 if (mg-mg_flags  MGf_REFCOUNTED)
do_sv_dump(level+2, file, mg-mg_obj, nest+1, maxnest, dumpops, 
pvlim); /* MG is already +1 */
End of Patch.


Change 30681: [PATCH] Re: [PATCH] lib/Pod/Html.pm plus a funky UT8-8 regex bug

2007-03-22 Thread Rafael Garcia-Suarez
Change 30681 by [EMAIL PROTECTED] on 2007/03/22 09:28:15

Subject: [PATCH] Re: [PATCH] lib/Pod/Html.pm plus a funky UT8-8 regex 
bug
From: Jarkko Hietaniemi [EMAIL PROTECTED]
Date: Wed, 21 Mar 2007 08:01:14 -0400
Message-ID: [EMAIL PROTECTED]

Affected files ...

... //depot/perl/lib/Pod/Html.pm#89 edit

Differences ...

 //depot/perl/lib/Pod/Html.pm#89 (text) 
Index: perl/lib/Pod/Html.pm
--- perl/lib/Pod/Html.pm#88~30631~  2007-03-19 02:34:32.0 -0700
+++ perl/lib/Pod/Html.pm2007-03-22 02:28:15.0 -0700
@@ -2099,13 +2099,12 @@
 
 my $orig = $text;
 
-# just clean the punctuation and leave the words for the
-# fragment identifier.
-$text =~ s/([[:punct:]\s])+/$1/g;
-$text =~ s/[[:punct:]\s]+\Z//g;
-
-#   =item --version, remove leading punctuation.
-$text =~ s/^[-[:punct:]]//;
+# leave the words for the fragment identifier,
+# change everything else to underbars.
+$text =~ s/[^A-Za-z0-9_]+/_/g; # do not use \W to avoid locale dependency.
+$text =~ s/_{2,}/_/g;
+$text =~ s/\A_//;
+$text =~ s/_\Z//;
 
 unless ($text)
 {
@@ -2129,11 +2128,11 @@
 }}
 
 my @HC;
-sub fragment_id_obfusticated {  # This was the old _2d_2d__
+sub fragment_id_obfuscated {  # This was the old _2d_2d__
 my $text = shift;
 my $generate = shift;   # optional flag
 
-# text? Normalize by obfusticating the fragment id to make it unique
+# text? Normalize by obfuscating the fragment id to make it unique
 $text =~ s/\s+/_/sg;
 
 $text =~ s{(\W)}{
@@ -2174,9 +2173,9 @@
return $1 if $text =~ m{^([a-z\d_]+)(\s+[A-Z,/ ][A-Z\d,/ ]*)?$};
return $1 if $text =~ m{^([a-z\d]+)\s+Module(\s+[A-Z\d,/ ]+)?$};
 
-   fragment_id_readable($text, $generate);
+   return fragment_id_readable($text, $generate);
 } else {
-   return undef();
+   return;
 }
 }
 
End of Patch.


Change 30677: [PATCH] threads 1.61

2007-03-22 Thread Rafael Garcia-Suarez
Change 30677 by [EMAIL PROTECTED] on 2007/03/22 08:34:42

Subject: [PATCH] threads 1.61
From: Jerry D. Hedden [EMAIL PROTECTED]
Date: Wed, 21 Mar 2007 13:15:53 -0700 (PDT)
Message-ID: [EMAIL PROTECTED]

Fix 'list/array' context - both keywords are supported

Affected files ...

... //depot/perl/ext/threads/Changes#36 edit
... //depot/perl/ext/threads/README#34 edit
... //depot/perl/ext/threads/t/context.t#5 edit
... //depot/perl/ext/threads/t/exit.t#15 edit
... //depot/perl/ext/threads/t/thread.t#40 edit
... //depot/perl/ext/threads/threads.pm#86 edit
... //depot/perl/ext/threads/threads.xs#139 edit

Differences ...

 //depot/perl/ext/threads/Changes#36 (xtext) 
Index: perl/ext/threads/Changes
--- perl/ext/threads/Changes#35~30152~  2007-02-06 14:37:34.0 -0800
+++ perl/ext/threads/Changes2007-03-22 01:34:42.0 -0700
@@ -1,5 +1,10 @@
 Revision history for Perl extension threads.
 
+1.61 Wed Mar 21 16:09:15 EDT 2007
+   - Fix 'list/array' context - both keywords are supported
+   - Upgraded ppport.h to Devel::PPPort 3.11
+   - Removed embed.t - unreliable
+
 1.59 - Mon Feb  5 16:05:44 EST 2007
- POD tweaks per Wolfgang Laun
 

 //depot/perl/ext/threads/README#34 (xtext) 
Index: perl/ext/threads/README
--- perl/ext/threads/README#33~30152~   2007-02-06 14:37:34.0 -0800
+++ perl/ext/threads/README 2007-03-22 01:34:42.0 -0700
@@ -1,4 +1,4 @@
-threads version 1.59
+threads version 1.61
 
 
 This module exposes interpreter threads to the Perl level.

 //depot/perl/ext/threads/t/context.t#5 (text) 
Index: perl/ext/threads/t/context.t
--- perl/ext/threads/t/context.t#4~28501~   2006-07-07 07:12:59.0 
-0700
+++ perl/ext/threads/t/context.t2007-03-22 01:34:42.0 -0700
@@ -65,7 +65,7 @@
 my $wantarray = wantarray();
 
 if ($wantarray) {
-ok($context eq 'array', 'Array context');
+ok($context eq 'array', 'Array/list context');
 return ('array');
 } elsif (defined($wantarray)) {
 ok($context eq 'scalar', 'Scalar context');
@@ -108,8 +108,8 @@
 my $wantarray = threads-wantarray();
 
 if ($wantarray) {
-ok($context eq 'array', 'Array context');
-return ('array');
+ok($context eq 'list', 'Array/list context');
+return ('list');
 } elsif (defined($wantarray)) {
 ok($context eq 'scalar', 'Scalar context');
 return 'scalar';
@@ -119,11 +119,11 @@
 }
 }
 
-($thr) = threads-create('bar', 'array');
+($thr) = threads-create('bar', 'list');
 my $ctx = $thr-wantarray();
 ok($ctx, 'Implicit array context');
 ($res) = $thr-join();
-ok($res eq 'array', 'Implicit array context');
+ok($res eq 'list', 'Implicit array context');
 
 $thr = threads-create('bar', 'scalar');
 $ctx = $thr-wantarray();
@@ -138,11 +138,11 @@
 $res = $thr-join();
 ok(! defined($res), 'Implicit void context');
 
-$thr = threads-create({'context' = 'array'}, 'bar', 'array');
+$thr = threads-create({'context' = 'list'}, 'bar', 'list');
 $ctx = $thr-wantarray();
 ok($ctx, 'Explicit array context');
 ($res) = $thr-join();
-ok($res eq 'array', 'Explicit array context');
+ok($res eq 'list', 'Explicit array context');
 
 ($thr) = threads-create({'scalar' = 'scalar'}, 'bar', 'scalar');
 $ctx = $thr-wantarray();

 //depot/perl/ext/threads/t/exit.t#15 (text) 
Index: perl/ext/threads/t/exit.t
--- perl/ext/threads/t/exit.t#14~30152~ 2007-02-06 14:37:34.0 -0800
+++ perl/ext/threads/t/exit.t   2007-03-22 01:34:42.0 -0700
@@ -56,7 +56,7 @@
 ok(! defined($rc), 'Exited: threads-exit()');
 
 
-run_perl(prog = 'use threads 1.59;' .
+run_perl(prog = 'use threads 1.61;' .
  'threads-exit(86);' .
  'exit(99);',
  nolib = ($ENV{PERL_CORE}) ? 0 : 1,
@@ -104,7 +104,7 @@
 ok(! defined($rc), 'Exited: $thr-set_thread_exit_only');
 
 
-run_perl(prog = 'use threads 1.59 qw(exit thread_only);' .
+run_perl(prog = 'use threads 1.61 qw(exit thread_only);' .
  'threads-create(sub { exit(99); })-join();' .
  'exit(86);',
  nolib = ($ENV{PERL_CORE}) ? 0 : 1,
@@ -112,7 +112,7 @@
 is($?8, 86, 'use threads 'exit' = 'thread_only');
 
 
-my $out = run_perl(prog = 'use threads 1.59;' .
+my $out = run_perl(prog = 'use threads 1.61;' .
'threads-create(sub {' .
'exit(99);' .
'});' .
@@ -125,7 +125,7 @@
 like($out, '1 finished and unjoined', exit(status) in thread);
 
 
-$out = run_perl(prog = 'use threads 1.59 qw(exit thread_only);' .
+$out = run_perl(prog = 'use threads 1.61 qw(exit thread_only);' .
 'threads-create(sub {' .
 '   threads-set_thread_exit_only(0);' .
 '   exit(99);' .
@@ -139,7 +139,7 @@
 like($out, '1 finished and unjoined', set_thread_exit_only(0));
 

Change 30678: [PATCH] Resolve PL_curpm issues with (??{}) and fix corruption of match results when pattern is a qr.

2007-03-22 Thread Rafael Garcia-Suarez
Change 30678 by [EMAIL PROTECTED] on 2007/03/22 09:01:37

Subject: [PATCH] Resolve PL_curpm issues with (??{}) and fix corruption 
of match results when pattern is a qr.
From: demerphq [EMAIL PROTECTED]
Date: Wed, 21 Mar 2007 10:39:24 +0100
Message-ID: [EMAIL PROTECTED]

plus two follow-up patches (minor tweaks)

Affected files ...

... //depot/perl/dump.c#257 edit
... //depot/perl/embed.fnc#471 edit
... //depot/perl/embed.h#672 edit
... //depot/perl/ext/Devel/Peek/t/Peek.t#28 edit
... //depot/perl/ext/Encode/t/Aliases.t#18 edit
... //depot/perl/ext/re/re.pm#48 edit
... //depot/perl/ext/re/t/re_funcs.t#8 edit
... //depot/perl/global.sym#328 edit
... //depot/perl/lib/Tie/Hash/NamedCapture.pm#3 edit
... //depot/perl/pp_ctl.c#605 edit
... //depot/perl/proto.h#808 edit
... //depot/perl/regcomp.c#565 edit
... //depot/perl/regcomp.h#119 edit
... //depot/perl/regexec.c#523 edit
... //depot/perl/regexp.h#92 edit
... //depot/perl/t/op/pat.t#282 edit
... //depot/perl/universal.c#158 edit

Differences ...

 //depot/perl/dump.c#257 (text) 
Index: perl/dump.c
--- perl/dump.c#256~30557~  2007-03-12 15:14:27.0 -0700
+++ perl/dump.c 2007-03-22 02:01:37.0 -0700
@@ -1263,8 +1263,20 @@
Perl_dump_indent(aTHX_ level, file,   MINMATCH\n);
 }
if (mg-mg_obj) {
-   Perl_dump_indent(aTHX_ level, file, MG_OBJ = 0x%UVxf\n, 
PTR2UV(mg-mg_obj));
-   if (mg-mg_flags  MGf_REFCOUNTED)
+   Perl_dump_indent(aTHX_ level, file, MG_OBJ = 0x%UVxf\n, 
+   PTR2UV(mg-mg_obj));
+if (mg-mg_type == PERL_MAGIC_qr) {
+regexp *re=(regexp *)mg-mg_obj;
+SV *dsv= sv_newmortal();
+const char * const s =  pv_pretty(dsv, re-wrapped, 
re-wraplen, 
+60, NULL, NULL,
+( PERL_PV_PRETTY_QUOTE | PERL_PV_ESCAPE_RE | 
PERL_PV_PRETTY_ELIPSES |
+((re-extflags  RXf_UTF8) ? PERL_PV_ESCAPE_UNI : 0))
+);
+Perl_dump_indent(aTHX_ level+1, file, PAT = %s\n, s);
+Perl_dump_indent(aTHX_ level+1, file, REFCNT = 
%IVdf\n, (IV*)re-refcnt);
+}
+if (mg-mg_flags  MGf_REFCOUNTED)
do_sv_dump(level+2, file, mg-mg_obj, nest+1, maxnest, dumpops, 
pvlim); /* MG is already +1 */
}
 if (mg-mg_len)

 //depot/perl/embed.fnc#471 (text) 
Index: perl/embed.fnc
--- perl/embed.fnc#470~30629~   2007-03-19 01:58:08.0 -0700
+++ perl/embed.fnc  2007-03-22 02:01:37.0 -0700
@@ -677,6 +677,7 @@
|NN char* strend|NN char* strbeg|I32 minend \
|NN SV* screamer|U32 nosave
 Ap |void   |pregfree   |NULLOK struct regexp* r
+EXp|struct regexp* |reg_temp_copy  |NN struct regexp* r
 Ap |void   |regfree_internal|NULLOK struct regexp* r
 Ap |char * |reg_stringify  |NN MAGIC *mg|NULLOK STRLEN *lp|NULLOK U32 
*flags|NULLOK I32 *haseval
 #if defined(USE_ITHREADS)

 //depot/perl/embed.h#672 (text+w) 
Index: perl/embed.h
--- perl/embed.h#671~30629~ 2007-03-19 01:58:08.0 -0700
+++ perl/embed.h2007-03-22 02:01:37.0 -0700
@@ -685,6 +685,9 @@
 #define regclass_swash Perl_regclass_swash
 #define pregexec   Perl_pregexec
 #define pregfree   Perl_pregfree
+#if defined(PERL_CORE) || defined(PERL_EXT)
+#define reg_temp_copy  Perl_reg_temp_copy
+#endif
 #define regfree_internal   Perl_regfree_internal
 #define reg_stringify  Perl_reg_stringify
 #if defined(USE_ITHREADS)
@@ -2906,6 +2909,9 @@
 #define regclass_swash(a,b,c,d,e)  Perl_regclass_swash(aTHX_ a,b,c,d,e)
 #define pregexec(a,b,c,d,e,f,g)Perl_pregexec(aTHX_ a,b,c,d,e,f,g)
 #define pregfree(a)Perl_pregfree(aTHX_ a)
+#if defined(PERL_CORE) || defined(PERL_EXT)
+#define reg_temp_copy(a)   Perl_reg_temp_copy(aTHX_ a)
+#endif
 #define regfree_internal(a)Perl_regfree_internal(aTHX_ a)
 #define reg_stringify(a,b,c,d) Perl_reg_stringify(aTHX_ a,b,c,d)
 #if defined(USE_ITHREADS)

 //depot/perl/ext/Devel/Peek/t/Peek.t#28 (text) 
Index: perl/ext/Devel/Peek/t/Peek.t
--- perl/ext/Devel/Peek/t/Peek.t#27~29693~  2007-01-05 01:55:22.0 
-0800
+++ perl/ext/Devel/Peek/t/Peek.t2007-03-22 02:01:37.0 -0700
@@ -282,6 +282,8 @@
   MG_VIRTUAL = $ADDR
   MG_TYPE = PERL_MAGIC_qr\(r\)
   MG_OBJ = $ADDR
+PAT = \(\?-xism:tic\)
+REFCNT = 2
 STASH = $ADDR\\tRegexp');
 
 do_test(16,

 //depot/perl/ext/Encode/t/Aliases.t#18 (text) 
Index: perl/ext/Encode/t/Aliases.t
--- perl/ext/Encode/t/Aliases.t#17~28098~   2006-05-04 05:06:33.0 
-0700
+++ perl/ext/Encode/t/Aliases.t 2007-03-22 02:01:37.0 -0700
@@ -122,6 +122,7 @@
 print # alias test;  \$ON_EBCDIC == $ON_EBCDIC\n;
 
 foreach my $a (keys %a2c){ 
+  

Change 30683: Re-order the flags values for struct refcounted_he to allow the

2007-03-22 Thread Nicholas Clark
Change 30683 by [EMAIL PROTECTED] on 2007/03/22 14:00:14

Re-order the flags values for struct refcounted_he to allow the
possibility of storing 2 futher types. Add a void * to the union
as it won't increase the size, but may become useful.

Affected files ...

... //depot/perl/hv.c#342 edit
... //depot/perl/hv.h#100 edit

Differences ...

 //depot/perl/hv.c#342 (text) 
Index: perl/hv.c
--- perl/hv.c#341~30440~2007-03-01 09:46:49.0 -0800
+++ perl/hv.c   2007-03-22 07:00:14.0 -0700
@@ -2581,11 +2581,13 @@
value = PL_sv_placeholder;
break;
 case HVrhek_IV:
-   value = (he-refcounted_he_data[0]  HVrhek_UV)
-   ? newSVuv(he-refcounted_he_val.refcounted_he_u_iv)
-   : newSViv(he-refcounted_he_val.refcounted_he_u_uv);
+   value = newSViv(he-refcounted_he_val.refcounted_he_u_iv);
+   break;
+case HVrhek_UV:
+   value = newSVuv(he-refcounted_he_val.refcounted_he_u_uv);
break;
 case HVrhek_PV:
+case HVrhek_PV_UTF8:
/* Create a string SV that directly points to the bytes in our
   structure.  */
value = newSV_type(SVt_PV);
@@ -2595,7 +2597,7 @@
SvLEN_set(value, 0);
SvPOK_on(value);
SvREADONLY_on(value);
-   if (he-refcounted_he_data[0]  HVrhek_UTF8)
+   if ((he-refcounted_he_data[0]  HVrhek_typemask) == HVrhek_PV_UTF8)
SvUTF8_on(value);
break;
 default:
@@ -2605,14 +2607,6 @@
 return value;
 }
 
-#ifdef USE_ITHREADS
-/* A big expression to find the key offset */
-#define REF_HE_KEY(chain) \
-   chain-refcounted_he_data[0]  HVrhek_typemask) == HVrhek_PV) \
-   ? chain-refcounted_he_val.refcounted_he_u_len + 1 : 0)   \
-+ 1 + chain-refcounted_he_data)
-#endif
-
 /*
 =for apidoc refcounted_he_chain_2hv
 
@@ -2821,7 +2815,6 @@
value_len = 0;
key_offset = 1;
 }
-flags = value_type;
 
 #ifdef USE_ITHREADS
 he = (struct refcounted_he*)
@@ -2840,17 +2833,19 @@
 if (value_type == HVrhek_PV) {
Copy(value_p, he-refcounted_he_data + 1, value_len + 1, char);
he-refcounted_he_val.refcounted_he_u_len = value_len;
-   if (SvUTF8(value)) {
-   flags |= HVrhek_UTF8;
-   }
+   /* Do it this way so that the SvUTF8() test is after the SvPV, in case
+  the value is overloaded, and doesn't yet have the UTF-8flag set.  */
+   if (SvUTF8(value))
+   value_type = HVrhek_PV_UTF8;
 } else if (value_type == HVrhek_IV) {
if (SvUOK(value)) {
he-refcounted_he_val.refcounted_he_u_uv = SvUVX(value);
-   flags |= HVrhek_UV;
+   value_type = HVrhek_UV;
} else {
he-refcounted_he_val.refcounted_he_u_iv = SvIVX(value);
}
 }
+flags = value_type;
 
 if (is_utf8) {
/* Hash keys are always stored normalised to (yes) ISO-8859-1.

 //depot/perl/hv.h#100 (text) 
Index: perl/hv.h
--- perl/hv.h#99~30520~ 2007-03-08 08:31:36.0 -0800
+++ perl/hv.h   2007-03-22 07:00:14.0 -0700
@@ -390,6 +390,8 @@
between threads (because it hangs from OPs, which are shared), hence the
alternate definition and mutex.  */
 
+struct refcounted_he;
+
 #ifdef PERL_CORE
 
 /* Gosh. This really isn't a good name any longer.  */
@@ -406,6 +408,7 @@
IVrefcounted_he_u_iv;
UVrefcounted_he_u_uv;
STRLENrefcounted_he_u_len;
+   void *refcounted_he_u_ptr;  /* Might be useful in future */
 } refcounted_he_val;
 /* First byte is flags. Then NUL-terminated value. Then for ithreads,
non-NUL terminated key.  */
@@ -414,12 +417,22 @@
 
 /* Flag bits are HVhek_UTF8, HVhek_WASUTF8, then */
 #define HVrhek_undef   0x00 /* Value is undef. */
-#define HVrhek_PV  0x10 /* Value is a string. */
-#define HVrhek_IV  0x20 /* Value is IV/UV. */
-#define HVrhek_delete  0x30 /* Value is placeholder - signifies delete. */
-#define HVrhek_typemask0x30
-#define HVrhek_UTF80x40 /* string value is utf8. */
-#define HVrhek_UV  0x40 /* integer value is UV. */
+#define HVrhek_delete  0x10 /* Value is placeholder - signifies delete. */
+#define HVrhek_IV  0x20 /* Value is IV. */
+#define HVrhek_UV  0x30 /* Value is UV. */
+#define HVrhek_PV  0x40 /* Value is a (byte) string. */
+#define HVrhek_PV_UTF8 0x50 /* Value is a (utf8) string. */
+/* Two spare. As these have to live in the optree, you can't store anything
+   interpreter specific, such as SVs. :-( */
+#define HVrhek_typemask 0x70
+
+#ifdef USE_ITHREADS
+/* A big expression to find the key offset */
+#define REF_HE_KEY(chain)  \
+   chain-refcounted_he_data[0]  0x60) == 0x40)   \
+   ? chain-refcounted_he_val.refcounted_he_u_len + 1 : 0) \
++ 1 + chain-refcounted_he_data)
+#endif
 
 #  ifdef USE_ITHREADS
 #

Change 30684: Fix internal POD link

2007-03-22 Thread Rafael Garcia-Suarez
Change 30684 by [EMAIL PROTECTED] on 2007/03/22 14:25:54

Fix internal POD link

Affected files ...

... //depot/perl/lib/Term/ANSIColor.pm#14 edit

Differences ...

 //depot/perl/lib/Term/ANSIColor.pm#14 (text) 
Index: perl/lib/Term/ANSIColor.pm
--- perl/lib/Term/ANSIColor.pm#13~28580~2006-07-15 08:22:35.0 
-0700
+++ perl/lib/Term/ANSIColor.pm  2007-03-22 07:25:54.0 -0700
@@ -32,7 +32,7 @@
  ON_CYAN ON_WHITE)]);
 Exporter::export_ok_tags ('constants');
 
-$VERSION = '1.11';
+$VERSION = '1.11_01';
 
 ##
 # Internal data structures
@@ -227,7 +227,7 @@
 
 This module has two interfaces, one through color() and colored() and the
 other through constants.  It also offers the utility function uncolor(),
-which has to be explicitly imported to be used (see LSYNOPSIS).
+which has to be explicitly imported to be used (see L/SYNOPSIS).
 
 color() takes any number of strings as arguments and considers them to be
 space-separated lists of attributes.  It then forms and returns the escape
End of Patch.


Change 30685: Remove references to perlcc from the core docs.

2007-03-22 Thread Rafael Garcia-Suarez
Change 30685 by [EMAIL PROTECTED] on 2007/03/22 14:37:43

Remove references to perlcc from the core docs.

Affected files ...

... //depot/perl/pod/perlfunc.pod#558 edit
... //depot/perl/pod/perlmod.pod#41 edit
... //depot/perl/pod/perlutil.pod#13 edit
... //depot/perl/pod/perlvar.pod#167 edit

Differences ...

 //depot/perl/pod/perlfunc.pod#558 (text) 
Index: perl/pod/perlfunc.pod
--- perl/pod/perlfunc.pod#557~30646~2007-03-19 16:59:54.0 -0700
+++ perl/pod/perlfunc.pod   2007-03-22 07:37:43.0 -0700
@@ -1406,20 +1406,11 @@
 be open any more when the program is reincarnated, with possible
 resulting confusion on the part of Perl.
 
-This function is now largely obsolete, partly because it's very
-hard to convert a core file into an executable, and because the
-real compiler backends for generating portable bytecode and compilable
-C code have superseded it.  That's why you should now invoke it as
-CCORE::dump(), if you don't want to be warned against a possible
+This function is now largely obsolete, mostly because it's very hard to
+convert a core file into an executable. That's why you should now invoke
+it as CCORE::dump(), if you don't want to be warned against a possible
 typo.
 
-If you're looking to use Ldump to speed up your program, consider
-generating bytecode or native C code as described in Lperlcc.  If
-you're just trying to accelerate a CGI script, consider using the
-Cmod_perl extension to BApache, or the CPAN module, CGI::Fast.
-You might also consider autoloading or selfloading, which at least
-make your program Iappear to run faster.
-
 =item each HASH
 Xeach Xhash, iterator
 

 //depot/perl/pod/perlmod.pod#41 (text) 
Index: perl/pod/perlmod.pod
--- perl/pod/perlmod.pod#40~29053~  2006-10-19 08:54:15.0 -0700
+++ perl/pod/perlmod.pod2007-03-22 07:37:43.0 -0700
@@ -323,9 +323,7 @@
 in the Perl compiler suite to save the compiled state of the program.
 
 CINIT blocks are run just before the Perl runtime begins execution, in
-first in, first out (FIFO) order. For example, the code generators
-documented in Lperlcc make use of CINIT blocks to initialize and
-resolve pointers to XSUBs.
+first in, first out (FIFO) order.
 
 When you use the B-n and B-p switches to Perl, CBEGIN and
 CEND work just as they do in Bawk, as a degenerate case.

 //depot/perl/pod/perlutil.pod#13 (text) 
Index: perl/pod/perlutil.pod
--- perl/pod/perlutil.pod#12~27390~ 2006-03-06 09:26:43.0 -0800
+++ perl/pod/perlutil.pod   2007-03-22 07:37:43.0 -0700
@@ -210,10 +210,6 @@
 which subroutines are taking up the most run time. See LDevel::DProf
 for more information.
 
-=item Lperlcc|perlcc
-
-Fperlcc is the interface to the experimental Perl compiler suite.
-
 =item Lprove
 
 Fprove is a command-line interface to the test-running functionality of
@@ -286,7 +282,7 @@
 Lroffitall|roffitall, La2p|a2p, Ls2p|s2p, Lfind2perl|find2perl,
 LFile::Find|File::Find, Lpl2pm|pl2pm, Lperlbug|perlbug,
 Lh2ph|h2ph, Lc2ph|c2ph, Lh2xs|h2xs, Ldprofpp|dprofpp,
-LDevel::DProf, Lperlcc|perlcc, Lenc2xs, Lxsubpp, Lcpan,
+LDevel::DProf, Lenc2xs, Lxsubpp, Lcpan,
 Linstmodsh, Lpiconv, Lprove, Lcorelist, Lptar, Lptardiff,
 Lshasum
 

 //depot/perl/pod/perlvar.pod#167 (text) 
Index: perl/pod/perlvar.pod
--- perl/pod/perlvar.pod#166~30517~ 2007-03-08 07:06:49.0 -0800
+++ perl/pod/perlvar.pod2007-03-22 07:37:43.0 -0700
@@ -1047,7 +1047,7 @@
 The current value of the flag associated with the B-c switch.
 Mainly of use with B-MO=... to allow code to alter its behavior
 when being compiled, such as for example to AUTOLOAD at compile
-time rather than normal, deferred loading.  See Lperlcc.  Setting
+time rather than normal, deferred loading.  Setting
 C$^C = 1 is similar to calling CB::minus_c.
 
 =item $DEBUGGING
End of Patch.


Change 30687: [PATCH] Fix to threads::shared t/waithires.t

2007-03-22 Thread Steve Peters
Change 30687 by [EMAIL PROTECTED] on 2007/03/22 14:43:32

Subject: [PATCH] Fix to threads::shared t/waithires.t
From: Jerry D. Hedden [EMAIL PROTECTED]
Date: Thu, 22 Mar 2007 07:34:23 -0700 (PDT)
Message-ID: [EMAIL PROTECTED]

Affected files ...

... //depot/perl/ext/threads/shared/t/waithires.t#3 edit

Differences ...

 //depot/perl/ext/threads/shared/t/waithires.t#3 (text) 
Index: perl/ext/threads/shared/t/waithires.t
--- perl/ext/threads/shared/t/waithires.t#2~30634~  2007-03-19 
08:42:58.0 -0700
+++ perl/ext/threads/shared/t/waithires.t   2007-03-22 07:43:32.0 
-0700
@@ -205,18 +205,12 @@
 die $test: unknown test\n;
   }
   $delta = time() - $delta;
-  if (($to  0) || ($^O eq 'os2')) {
-ok(2, ! defined($ok), $test: timeout);
-  } else {
-# This is a bit problematic, as scheduling and compute latencies
-# can inject delays in our computation. For now, assume -10/+20%
-# is reasonable
-if (! ok(2, ! defined($ok) 
-($delta  (0.9 * $to)) 
-($delta  (1.2 * $to)),
-$test: timeout))
-{
-print(STDERR # Timeout: specified=$to  actual=$delta secs.\n);
+  ok(2, ! defined($ok), $test: timeout);
+
+  if (($to  0)  ($^O ne 'os2')) {
+# Timing tests can be problematic
+if (($delta  (0.9 * $to)) || ($delta  (1.0 + $to))) {
+  print(STDERR # Timeout: specified=$to  actual=$delta secs.\n);
 }
   }
 }
@@ -322,14 +316,12 @@
 die $test: unknown test\n;
   }
   $delta = time() - $delta;
-  if (($to  0) || ($^O eq 'os2')) {
-ok(2,!$ok, $test: timeout);
-  } else {
-if (ok(2, ! $ok, $test: timeout)) {
-  # Timing tests can be problematic
-  if (($delta  (0.9 * $to)) || ($delta  (1.0 + $to))) {
-print(STDERR # Timeout: specified=$to  actual=$delta secs.\n);
-  }
+  ok(2, ! $ok, $test: timeout);
+
+  if (($to  0)  ($^O ne 'os2')) {
+# Timing tests can be problematic
+if (($delta  (0.9 * $to)) || ($delta  (1.0 + $to))) {
+  print(STDERR # Timeout: specified=$to  actual=$delta secs.\n);
 }
   }
 }
End of Patch.


Change 30686: Fix a broken link and a meaningless phrase in perldebguts

2007-03-22 Thread Rafael Garcia-Suarez
Change 30686 by [EMAIL PROTECTED] on 2007/03/22 14:41:17

Fix a broken link and a meaningless phrase in perldebguts

Affected files ...

... //depot/perl/pod/perldebguts.pod#19 edit

Differences ...

 //depot/perl/pod/perldebguts.pod#19 (text) 
Index: perl/pod/perldebguts.pod
--- perl/pod/perldebguts.pod#18~25118~  2005-07-12 01:46:13.0 -0700
+++ perl/pod/perldebguts.pod2007-03-22 07:41:17.0 -0700
@@ -191,9 +191,8 @@
 
 =item *
 
-See Lperldebug/Options for description of options parsed by
-CDB::parse_options(string) parses debugger options; see
-Lpperldebug/Options for a description of options recognized.
+See Lperldebug/Configurable Options for a description of options parsed by
+CDB::parse_options(string).
 
 =item *
 
End of Patch.


Change 30688: Misc. L fixes in core docs : don't link to man pages;

2007-03-22 Thread Rafael Garcia-Suarez
Change 30688 by [EMAIL PROTECTED] on 2007/03/22 14:45:36

Misc. L fixes in core docs : don't link to man pages;
provide full urls when linking to web sites.

Affected files ...

... //depot/perl/pod/perlipc.pod#66 edit
... //depot/perl/pod/perllocale.pod#40 edit
... //depot/perl/pod/perlpacktut.pod#14 edit

Differences ...

 //depot/perl/pod/perlipc.pod#66 (text) 
Index: perl/pod/perlipc.pod
--- perl/pod/perlipc.pod#65~30525~  2007-03-09 09:47:22.0 -0800
+++ perl/pod/perlipc.pod2007-03-22 07:45:36.0 -0700
@@ -543,7 +543,7 @@
 The fork() has to come before the setsid() to ensure that you aren't a
 process group leader (the setsid() will fail if you are).  If your
 system doesn't have the setsid() function, open F/dev/tty and use the
-CTIOCNOTTY ioctl() on it instead.  See Ltty(4) for details.
+CTIOCNOTTY ioctl() on it instead.  See tty(4) for details.
 
 Non-Unix users should check their Your_OS::Process module for other
 solutions.

 //depot/perl/pod/perllocale.pod#40 (text) 
Index: perl/pod/perllocale.pod
--- perl/pod/perllocale.pod#39~28965~   2006-10-08 10:07:42.0 -0700
+++ perl/pod/perllocale.pod 2007-03-22 07:45:36.0 -0700
@@ -177,7 +177,7 @@
 If no second argument is provided and the category is LC_ALL, the
 result is implementation-dependent.  It may be a string of
 concatenated locales names (separator also implementation-dependent)
-or a single locale name.  Please consult your Lsetlocale(3) for
+or a single locale name.  Please consult your setlocale(3) man page for
 details.
 
 If a second argument is given and it corresponds to a valid locale,
@@ -197,11 +197,11 @@
 If the second argument does not correspond to a valid locale, the locale
 for the category is not changed, and the function returns Iundef.
 
-For further information about the categories, consult Lsetlocale(3).
+For further information about the categories, consult setlocale(3).
 
 =head2 Finding locales
 
-For locales available in your system, consult also Lsetlocale(3) to
+For locales available in your system, consult also setlocale(3) to
 see whether it leads to the list of available locales (search for the
 ISEE ALSO section).  If that fails, try the following command lines:
 
@@ -289,7 +289,7 @@
 other locale variables) may affect other programs as well, not just
 Perl.  In particular, external programs run from within Perl will see
 these changes.  If you make the new settings permanent (read on), all
-programs you run see the changes.  See LENVIRONMENT for
+programs you run see the changes.  See LENVIRONMENT for
 the full list of relevant environment variables and LUSING LOCALES
 for their effects in Perl.  Effects in other programs are 
 easily deducible.  For example, the variable LC_COLLATE may well affect

 //depot/perl/pod/perlpacktut.pod#14 (text) 
Index: perl/pod/perlpacktut.pod
--- perl/pod/perlpacktut.pod#13~30493~  2007-03-07 05:23:23.0 -0800
+++ perl/pod/perlpacktut.pod2007-03-22 07:45:36.0 -0700
@@ -623,7 +623,7 @@
 range, up to 255. After some more Latin extensions we find the character
 sets from languages using non-Roman alphabets, interspersed with a
 variety of symbol sets such as currency symbols, Zapf Dingbats or Braille.
-(You might want to visit Lwww.unicode.org for a look at some of
+(You might want to visit Lhttp://www.unicode.org/ for a look at some of
 them - my personal favourites are Telugu and Kannada.)
 
 The Unicode character sets associates characters with integers. Encoding
@@ -668,7 +668,7 @@
 
 The pack code Cw has been added to support a portable binary data
 encoding scheme that goes way beyond simple integers. (Details can
-be found at LCasbah.org, the Scarab project.)  A BER (Binary Encoded
+be found at Lhttp://Casbah.org/, the Scarab project.)  A BER (Binary Encoded
 Representation) compressed unsigned integer stores base 128
 digits, most significant digit first, with as few digits as possible.
 Bit eight (the high bit) is set on each byte except the last. There
End of Patch.


Change 30690: Make opcode.pl strict clean. (threadsv, a 5005-threads specific term,

2007-03-22 Thread Nicholas Clark
Change 30690 by [EMAIL PROTECTED] on 2007/03/22 15:57:52

Make opcode.pl strict clean. (threadsv, a 5005-threads specific term,
was a bareword.)

Affected files ...

... //depot/maint-5.8/perl/opcode.pl#34 edit

Differences ...

 //depot/maint-5.8/perl/opcode.pl#34 (xtext) 
Index: perl/opcode.pl
--- perl/opcode.pl#33~30272~2007-02-13 15:24:02.0 -0800
+++ perl/opcode.pl  2007-03-22 08:57:52.0 -0700
@@ -230,7 +230,7 @@
 
 for (@ops) {
 $_ eq custom and next;
-if ($_ eq threadsv) {
+if ($_ eq 'threadsv') {
# Big threadsv special case
my $name = $alias{$_};
print EOT;
End of Patch.


Change 30692: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30692 by [EMAIL PROTECTED] on 2007/03/22 17:55:41

Integrate:
[ 28891]
Subject: [PATCH] Add hook for re_dup() into regex engine as reg_dupe 
(make re
From: demerphq [EMAIL PROTECTED]
Message-ID: [EMAIL PROTECTED]
Date: Sun, 17 Sep 2006 14:57:57 +0200

[ 28893]
Make Perl_regdupe only exist for threaded perls.

[ 28894]
I think we need to skip PL_regdupe as well as Perl_regdupe
when USE_ITHREADS is not defined

See: http://www.nntp.perl.org/group/perl.daily-build.reports/41274

Affected files ...

... //depot/maint-5.8/perl/embed.fnc#215 integrate
... //depot/maint-5.8/perl/embed.h#161 integrate
... //depot/maint-5.8/perl/embedvar.h#62 integrate
... //depot/maint-5.8/perl/ext/re/re.xs#3 integrate
... //depot/maint-5.8/perl/ext/re/re_top.h#2 integrate
... //depot/maint-5.8/perl/global.sym#65 integrate
... //depot/maint-5.8/perl/intrpvar.h#52 edit
... //depot/maint-5.8/perl/makedef.pl#44 integrate
... //depot/maint-5.8/perl/perl.h#165 integrate
... //depot/maint-5.8/perl/perlapi.h#54 integrate
... //depot/maint-5.8/perl/proto.h#207 integrate
... //depot/maint-5.8/perl/regcomp.c#104 edit
... //depot/maint-5.8/perl/sv.c#348 edit
... //depot/maint-5.8/perl/thrdvar.h#10 edit

Differences ...

 //depot/maint-5.8/perl/embed.fnc#215 (text) 
Index: perl/embed.fnc
--- perl/embed.fnc#214~30547~   2007-03-12 06:52:55.0 -0700
+++ perl/embed.fnc  2007-03-22 10:55:41.0 -0700
@@ -661,6 +661,9 @@
|NN char* strend|NN char* strbeg|I32 minend \
|NN SV* screamer|U32 nosave
 Ap |void   |pregfree   |NULLOK struct regexp* r
+#if defined(USE_ITHREADS)
+Ap |regexp*|regdupe|NN const regexp* r|NN CLONE_PARAMS* param
+#endif
 Ap |regexp*|pregcomp   |NN char* exp|NN char* xend|NN PMOP* pm
 Ap |char*  |re_intuit_start|NN regexp* prog|NULLOK SV* sv|NN char* strpos \
|NN char* strend|U32 flags \

 //depot/maint-5.8/perl/embed.h#161 (text+w) 
Index: perl/embed.h
--- perl/embed.h#160~30480~ 2007-03-05 15:40:56.0 -0800
+++ perl/embed.h2007-03-22 10:55:41.0 -0700
@@ -683,6 +683,9 @@
 #define regclass_swash Perl_regclass_swash
 #define pregexec   Perl_pregexec
 #define pregfree   Perl_pregfree
+#if defined(USE_ITHREADS)
+#define regdupePerl_regdupe
+#endif
 #define pregcomp   Perl_pregcomp
 #define re_intuit_startPerl_re_intuit_start
 #define re_intuit_string   Perl_re_intuit_string
@@ -2784,6 +2787,9 @@
 #define regclass_swash(a,b,c,d)Perl_regclass_swash(aTHX_ a,b,c,d)
 #define pregexec(a,b,c,d,e,f,g)Perl_pregexec(aTHX_ a,b,c,d,e,f,g)
 #define pregfree(a)Perl_pregfree(aTHX_ a)
+#if defined(USE_ITHREADS)
+#define regdupe(a,b)   Perl_regdupe(aTHX_ a,b)
+#endif
 #define pregcomp(a,b,c)Perl_pregcomp(aTHX_ a,b,c)
 #define re_intuit_start(a,b,c,d,e,f)   Perl_re_intuit_start(aTHX_ a,b,c,d,e,f)
 #define re_intuit_string(a)Perl_re_intuit_string(aTHX_ a)

 //depot/maint-5.8/perl/embedvar.h#62 (text+w) 
Index: perl/embedvar.h
--- perl/embedvar.h#61~30269~   2007-02-13 13:18:26.0 -0800
+++ perl/embedvar.h 2007-03-22 10:55:41.0 -0700
@@ -397,6 +397,7 @@
 #define PL_ptr_table   (PERL_GET_INTERP-Iptr_table)
 #define PL_reentrant_buffer(PERL_GET_INTERP-Ireentrant_buffer)
 #define PL_reentrant_retint(PERL_GET_INTERP-Ireentrant_retint)
+#define PL_regdupe (PERL_GET_INTERP-Iregdupe)
 #define PL_regex_pad   (PERL_GET_INTERP-Iregex_pad)
 #define PL_regex_padav (PERL_GET_INTERP-Iregex_padav)
 #define PL_rehash_seed (PERL_GET_INTERP-Irehash_seed)
@@ -727,6 +728,7 @@
 #define PL_ptr_table   (vTHX-Iptr_table)
 #define PL_reentrant_buffer(vTHX-Ireentrant_buffer)
 #define PL_reentrant_retint(vTHX-Ireentrant_retint)
+#define PL_regdupe (vTHX-Iregdupe)
 #define PL_regex_pad   (vTHX-Iregex_pad)
 #define PL_regex_padav (vTHX-Iregex_padav)
 #define PL_rehash_seed (vTHX-Irehash_seed)
@@ -1060,6 +1062,7 @@
 #define PL_Iptr_table  PL_ptr_table
 #define PL_Ireentrant_buffer   PL_reentrant_buffer
 #define PL_Ireentrant_retint   PL_reentrant_retint
+#define PL_IregdupePL_regdupe
 #define PL_Iregex_pad  PL_regex_pad
 #define PL_Iregex_padavPL_regex_padav
 #define PL_Irehash_seedPL_rehash_seed

 //depot/maint-5.8/perl/ext/re/re.xs#3 (text) 
Index: perl/ext/re/re.xs
--- perl/ext/re/re.xs#2~30615~  2007-03-18 12:48:25.0 -0700
+++ perl/ext/re/re.xs   2007-03-22 10:55:41.0 -0700
@@ -19,6 +19,9 @@
struct re_scream_pos_data_s *data);
 extern SV* my_re_intuit_string (pTHX_ regexp 

Change 30691: Make sure Win32CORE.pm gets cleaned up

2007-03-22 Thread Steve Hay
Change 30691 by [EMAIL PROTECTED] on 2007/03/22 17:46:43

Make sure Win32CORE.pm gets cleaned up

Normally it happens anyway, but sometimes when running 'distclean'
on a half-built source tree it gets left behind.

Affected files ...

... //depot/perl/win32/Makefile#328 edit
... //depot/perl/win32/makefile.mk#365 edit

Differences ...

 //depot/perl/win32/Makefile#328 (text) 
Index: perl/win32/Makefile
--- perl/win32/Makefile#327~30379~  2007-02-22 01:09:31.0 -0800
+++ perl/win32/Makefile 2007-03-22 10:46:43.0 -0700
@@ -1124,6 +1124,7 @@
-del /f $(LIBDIR)\Unicode\Normalize.pm
-del /f $(LIBDIR)\Math\BigInt\FastCalc.pm
-del /f $(LIBDIR)\Win32.pm
+   -del /f $(LIBDIR)\Win32CORE.pm
-del /f $(LIBDIR)\Win32API\File.pm
-del /f $(LIBDIR)\Win32API\File\cFile.pc
-if exist $(LIBDIR)\B rmdir /s /q $(LIBDIR)\B

 //depot/perl/win32/makefile.mk#365 (text) 
Index: perl/win32/makefile.mk
--- perl/win32/makefile.mk#364~30379~   2007-02-22 01:09:31.0 -0800
+++ perl/win32/makefile.mk  2007-03-22 10:46:43.0 -0700
@@ -1451,6 +1451,7 @@
-del /f $(LIBDIR)\Unicode\Normalize.pm
-del /f $(LIBDIR)\Math\BigInt\FastCalc.pm
-del /f $(LIBDIR)\Win32.pm
+   -del /f $(LIBDIR)\Win32CORE.pm
-del /f $(LIBDIR)\Win32API\File.pm
-del /f $(LIBDIR)\Win32API\File\cFile.pc
-if exist $(LIBDIR)\B rmdir /s /q $(LIBDIR)\B
End of Patch.


Change 30693: [PATCH] Re: [perl #32687] Encode::is_utf8 on tainted UTF8 string

2007-03-22 Thread Rafael Garcia-Suarez
Change 30693 by [EMAIL PROTECTED] on 2007/03/22 18:26:36

Subject: [PATCH] Re: [perl #32687] Encode::is_utf8 on tainted UTF8 
string
From: Rafael Garcia-Suarez [EMAIL PROTECTED]
Date: Thu, 16 Nov 2006 17:36:44 +0100
Message-ID: [EMAIL PROTECTED]

Affected files ...

... //depot/perl/ext/Encode/Encode.xs#124 edit

Differences ...

 //depot/perl/ext/Encode/Encode.xs#124 (text) 
Index: perl/ext/Encode/Encode.xs
--- perl/ext/Encode/Encode.xs#123~28974~2006-10-09 07:29:52.0 
-0700
+++ perl/ext/Encode/Encode.xs   2007-03-22 11:26:36.0 -0700
@@ -757,15 +757,11 @@
 {
 if (SvGMAGICAL(sv)) /* it could be $1, for example */
 sv = newSVsv(sv); /* GMAGIG will be done */
-if (SvPOK(sv)) {
 RETVAL = SvUTF8(sv) ? TRUE : FALSE;
 if (RETVAL 
 check  
 !is_utf8_string((U8*)SvPVX(sv), SvCUR(sv)))
 RETVAL = FALSE;
-} else {
-RETVAL = FALSE;
-}
 if (sv != ST(0))
 SvREFCNT_dec(sv); /* it was a temp copy */
 }
End of Patch.


Change 30694: Integrate the tests from:

2007-03-22 Thread Nicholas Clark
Change 30694 by [EMAIL PROTECTED] on 2007/03/22 19:09:14

Integrate the tests from:
[ 28906]
add stress test for CURLYX/WHILEM regex ops

[ 28944]
migrate CURLYX/WHILEM branch in regmatch() to new FSM-esque paradigm

Affected files ...

... //depot/maint-5.8/perl/t/op/pat.t#44 integrate

Differences ...

 //depot/maint-5.8/perl/t/op/pat.t#44 (xtext) 
Index: perl/t/op/pat.t
--- perl/t/op/pat.t#43~30663~   2007-03-21 11:17:59.0 -0700
+++ perl/t/op/pat.t 2007-03-22 12:09:14.0 -0700
@@ -7,7 +7,7 @@
 $| = 1;
 
 # please update note at bottom of file when you change this
-print 1..1247\n;
+print 1..1248\n;
 
 BEGIN {
 chdir 't' if -d 't';
@@ -3660,4 +3660,108 @@
 }
 
 
-# last test 1247
+# stress test CURLYX/WHILEM.
+#
+# This test includes varying levels of nesting, and according to
+# profiling done against build 28905, exercises every code line in the
+# CURLYX and WHILEM blocks, except those related to LONGJMP, the
+# super-linear cache and warnings. It executes about 0.5M regexes
+
+{
+  my $r = qr/^
+   (?:
+   ( (?:a|z+)+ )
+   (?:
+   ( (?:b|z+){3,}? )
+   (
+   (?:
+   (?:
+   (?:c|z+){1,1}?z
+   )?
+   (?:c|z+){1,1}
+   )*
+   )
+   (?:z*){2,}
+   ( (?:z+|d)+ )
+   (?:
+   ( (?:e|z+)+ )
+   )*
+   ( (?:f|z+)+ )
+   )*
+   ( (?:z+|g)+ )
+   (?:
+   ( (?:h|z+)+ )
+   )*
+   ( (?:i|z+)+ )
+   )+
+   ( (?:j|z+)+ )
+   (?:
+   ( (?:k|z+)+ )
+   )*
+   ( (?:l|z+)+ )
+   $/x;
+  
+  
+  my $ok = 1;
+  my $msg = CURLYX stress test;
+  OUTER:
+  for my $a (x,a,aa) {
+for my $b (x,bbb,) {
+  my $bs = $a.$b;
+  for my $c (x,c,cc) {
+my $cs = $bs.$c;
+for my $d (x,d,dd) {
+  my $ds = $cs.$d;
+  for my $e (x,e,ee) {
+my $es = $ds.$e;
+for my $f (x,f,ff) {
+  my $fs = $es.$f;
+  for my $g (x,g,gg) {
+my $gs = $fs.$g;
+for my $h (x,h,hh) {
+  my $hs = $gs.$h;
+  for my $i (x,i,ii) {
+my $is = $hs.$i;
+for my $j (x,j,jj) {
+  my $js = $is.$j;
+  for my $k (x,k,kk) {
+my $ks = $js.$k;
+for my $l (x,l,ll) {
+  my $ls = $ks.$l;
+  if ($ls =~ $r) {
+if ($ls =~ /x/) {
+  $msg .= : unexpected match for [$ls];
+ $ok = 0;
+  last OUTER;
+}
+my $cap = $1$2$3$4$5$6$7$8$9$10$11$12;
+unless ($ls eq $cap) {
+  $msg .= : capture: [$ls], got [$cap];
+ $ok = 0;
+  last OUTER;
+}
+  }
+  else {
+unless ($ls =~ /x/) {
+  $msg = : failed for [$ls];
+ $ok = 0;
+  last OUTER;
+}
+  }
+}
+  }
+}
+  }
+}
+  }
+}
+  }
+}
+  }
+}
+  }
+  ok($ok, $msg);
+}
+
+
+# last test 1248
End of Patch.


Change 30695: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30695 by [EMAIL PROTECTED] on 2007/03/22 20:59:51

Integrate:
[ 29056]
Subject: Re: Off by one in the trie code?
From: demerphq [EMAIL PROTECTED]
Date: Wed, 18 Oct 2006 20:51:41 +0200
Message-ID: [EMAIL PROTECTED]

change test files that do a require ./test.pl; without a BEGIN block
to ensure prototypes are seen, plus fix any breakage this reveals.

[ 29178]
Regression test by Yves Orton for : [perl #36046] Special var @-
becomes arbitrarily large

Affected files ...

... //depot/maint-5.8/perl/ext/Devel/Peek/t/Peek.t#13 integrate
... //depot/maint-5.8/perl/ext/POSIX/t/posix.t#11 integrate
... //depot/maint-5.8/perl/lib/vmsish.t#6 integrate
... //depot/maint-5.8/perl/t/comp/parser.t#22 integrate
... //depot/maint-5.8/perl/t/comp/utf.t#5 integrate
... //depot/maint-5.8/perl/t/io/argv.t#4 integrate
... //depot/maint-5.8/perl/t/io/utf8.t#12 integrate
... //depot/maint-5.8/perl/t/op/pat.t#45 integrate
... //depot/maint-5.8/perl/t/op/stash.t#4 integrate
... //depot/maint-5.8/perl/t/run/switchC.t#5 integrate
... //depot/maint-5.8/perl/t/run/switchd.t#8 integrate
... //depot/maint-5.8/perl/t/run/switches.t#8 integrate

Differences ...

 //depot/maint-5.8/perl/ext/Devel/Peek/t/Peek.t#13 (text) 
Index: perl/ext/Devel/Peek/t/Peek.t
--- perl/ext/Devel/Peek/t/Peek.t#12~30341~  2007-02-17 09:38:25.0 
-0800
+++ perl/ext/Devel/Peek/t/Peek.t2007-03-22 13:59:51.0 -0700
@@ -10,7 +10,7 @@
 }
 }
 
-require ./test.pl;
+BEGIN { require ./test.pl; }
 
 use Devel::Peek;
 

 //depot/maint-5.8/perl/ext/POSIX/t/posix.t#11 (text) 
Index: perl/ext/POSIX/t/posix.t
--- perl/ext/POSIX/t/posix.t#10~30522~  2007-03-09 09:20:49.0 -0800
+++ perl/ext/POSIX/t/posix.t2007-03-22 13:59:51.0 -0700
@@ -10,7 +10,7 @@
 }
 }
 
-require ./test.pl;
+BEGIN { require ./test.pl; }
 plan(tests = 66);
 
 use POSIX qw(fcntl_h signal_h limits_h _exit getcwd open read strftime write

 //depot/maint-5.8/perl/lib/vmsish.t#6 (text) 
Index: perl/lib/vmsish.t
--- perl/lib/vmsish.t#5~30159~  2007-02-07 08:57:11.0 -0800
+++ perl/lib/vmsish.t   2007-03-22 13:59:51.0 -0700
@@ -10,7 +10,7 @@
 
 my $Invoke_Perl = qq(MCR $perl -I[-.lib]);
 
-require ./test.pl;
+BEGIN { require ./test.pl; }
 plan(tests = 25);
 
 SKIP: {

 //depot/maint-5.8/perl/t/comp/parser.t#22 (text) 
Index: perl/t/comp/parser.t
--- perl/t/comp/parser.t#21~30663~  2007-03-21 11:17:59.0 -0700
+++ perl/t/comp/parser.t2007-03-22 13:59:51.0 -0700
@@ -8,7 +8,7 @@
 @INC = '../lib';
 }
 
-require ./test.pl;
+BEGIN { require ./test.pl; }
 plan( tests = 95 );
 
 eval '[EMAIL PROTECTED];';

 //depot/maint-5.8/perl/t/comp/utf.t#5 (text) 
Index: perl/t/comp/utf.t
--- perl/t/comp/utf.t#4~22986~  2004-06-23 08:30:36.0 -0700
+++ perl/t/comp/utf.t   2007-03-22 13:59:51.0 -0700
@@ -18,7 +18,7 @@
 }
 }
 
-require ./test.pl;
+BEGIN { require ./test.pl; }
 
 plan(tests = 15);
 

 //depot/maint-5.8/perl/t/io/argv.t#4 (xtext) 
Index: perl/t/io/argv.t
--- perl/t/io/argv.t#3~26697~   2006-01-07 05:18:30.0 -0800
+++ perl/t/io/argv.t2007-03-22 13:59:51.0 -0700
@@ -5,7 +5,7 @@
 @INC = '../lib';
 }
 
-require ./test.pl;
+BEGIN { require ./test.pl; }
 
 plan(tests = 22);
 

 //depot/maint-5.8/perl/t/io/utf8.t#12 (xtext) 
Index: perl/t/io/utf8.t
--- perl/t/io/utf8.t#11~30498~  2007-03-07 09:01:50.0 -0800
+++ perl/t/io/utf8.t2007-03-22 13:59:51.0 -0700
@@ -11,7 +11,7 @@
 
 no utf8; # needed for use utf8 not griping about the raw octets
 
-require ./test.pl;
+BEGIN { require ./test.pl; }
 
 plan(tests = 55);
 
@@ -231,7 +231,7 @@
 print F chr(0x100);
 close(F);
 
-isnt( defined $@ );
+isnt( defined $@, !0 );
 
 undef $@;
 open F, a;
@@ -239,7 +239,7 @@
 print F chr(0x100);
 close(F);
 
-isnt( defined $@ );
+isnt( defined $@, !0 );
 
 no warnings 'utf8';
 
@@ -248,7 +248,7 @@
 print F chr(0x100);
 close(F);
 
-isnt( defined $@ );
+isnt( defined $@, !0 );
 
 use warnings 'utf8';
 

 //depot/maint-5.8/perl/t/op/pat.t#45 (xtext) 
Index: perl/t/op/pat.t
--- perl/t/op/pat.t#44~30694~   2007-03-22 12:09:14.0 -0700
+++ perl/t/op/pat.t 2007-03-22 13:59:51.0 -0700
@@ -6,9 +6,6 @@
 
 $| = 1;
 
-# please update note at bottom of file when you change this
-print 1..1248\n;
-
 BEGIN {
 chdir 't' if -d 't';
 @INC = '../lib';
@@ -3763,5 +3760,16 @@
   ok($ok, $msg);
 }
 
+{
+my $str='abc'; 
+my $count=0;
+my $mval=0;
+my $pval=0;
+while ($str=~/b/g) { $mval=$#-; $pval=$#+; $count++ }
+iseq($mval,0,[EMAIL PROTECTED] should be empty [RT#36046]);
+iseq($pval,0,[EMAIL PROTECTED] should be empty [RT#36046]);
+iseq($count,1,should have matched once only [RT#36046]);
+}
 
-# last test 1248
+# Don't 

Change 30696: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30696 by [EMAIL PROTECTED] on 2007/03/22 21:20:38

Integrate:
[ 29156]
$hex is already hex, so cannot be used in %X if starting with [A-F]

[ 29353]
Subject: POSIX::remove() and directories
From: Dintelmann, Peter [EMAIL PROTECTED]
Date: Wed, 22 Nov 2006 17:41:55 +0100
Message-ID: [EMAIL PROTECTED]

Affected files ...

... //depot/maint-5.8/perl/ext/POSIX/POSIX.pm#15 integrate
... //depot/maint-5.8/perl/lib/charnames.pm#11 integrate

Differences ...

 //depot/maint-5.8/perl/ext/POSIX/POSIX.pm#15 (text) 
Index: perl/ext/POSIX/POSIX.pm
--- perl/ext/POSIX/POSIX.pm#14~30674~   2007-03-21 16:14:31.0 -0700
+++ perl/ext/POSIX/POSIX.pm 2007-03-22 14:20:38.0 -0700
@@ -372,7 +372,7 @@
 
 sub remove {
 usage remove(filename) if @_ != 1;
-CORE::unlink($_[0]);
+(-d $_[0]) ? CORE::rmdir($_[0]) : CORE::unlink($_[0]);
 }
 
 sub rename {

 //depot/maint-5.8/perl/lib/charnames.pm#11 (text) 
Index: perl/lib/charnames.pm
--- perl/lib/charnames.pm#10~25569~ 2005-09-22 05:44:27.0 -0700
+++ perl/lib/charnames.pm   2007-03-22 14:20:38.0 -0700
@@ -263,7 +263,7 @@
 
   # checking the length first is slightly faster
   if (length($hex)  5  hex($hex)  0x10) {
-carp sprintf Unicode characters only allocated up to U+10 (you asked 
for U+%X), $hex;
+carp Unicode characters only allocated up to U+10 (you asked for 
U+$hex);
 return;
   }
 
End of Patch.


Change 30697: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30697 by [EMAIL PROTECTED] on 2007/03/22 21:37:42

Integrate:
[ 29202]
Subject: [PATCH] New test for close-on-exec ($^F): t/run/cloexec.t
From: Andrew Savige [EMAIL PROTECTED]
Date: Sat, 4 Nov 2006 21:24:14 +1100 (EST)
Message-ID: [EMAIL PROTECTED]

[ 29212]
Subject: [PATCH] Re: the new t/run/cloexec.t failing in Solaris and 
Tru64
From: Andrew Savige [EMAIL PROTECTED]
Date: Tue, 7 Nov 2006 00:06:46 +1100 (EST)
Message-ID: [EMAIL PROTECTED]

[ 30078]
Subject: [PATCH] Re: run/cloexec.t is failing
From: Marcus Holland-Moritz [EMAIL PROTECTED]
Date: Sat, 13 Jan 2007 18:44:53 +0100
Message-ID: [EMAIL PROTECTED]

Affected files ...

... //depot/maint-5.8/perl/MANIFEST#352 integrate
... //depot/maint-5.8/perl/t/run/cloexec.t#1 branch

Differences ...

 //depot/maint-5.8/perl/MANIFEST#352 (text) 
Index: perl/MANIFEST
--- perl/MANIFEST#351~30587~2007-03-14 10:18:42.0 -0700
+++ perl/MANIFEST   2007-03-22 14:37:42.0 -0700
@@ -3055,6 +3055,7 @@
 t/pod/testpods/lib/Pod/Stuff.pmSample data for find.t
 t/pod/twice.t  Test Pod::Parser
 t/README   Instructions for regression tests
+t/run/cloexec.tTest close-on-exec.
 t/run/exit.t   Test perl's exit status.
 t/run/fresh_perl.t Tests that require a fresh perl.
 t/run/noswitch.t   Test aliasing ARGV for other switch tests

 //depot/maint-5.8/perl/t/run/cloexec.t#1 (text) 
Index: perl/t/run/cloexec.t
--- /dev/null   2007-03-19 09:41:43.516454971 -0700
+++ perl/t/run/cloexec.t2007-03-22 14:37:42.0 -0700
@@ -0,0 +1,174 @@
+#!./perl
+#
+# Test inheriting file descriptors across exec (close-on-exec).
+#
+# perlvar describes $^F aka $SYSTEM_FD_MAX as follows:
+#
+#  The maximum system file descriptor, ordinarily 2.  System file
+#  descriptors are passed to exec()ed processes, while higher file
+#  descriptors are not.  Also, during an open(), system file descriptors
+#  are preserved even if the open() fails.  (Ordinary file descriptors
+#  are closed before the open() is attempted.)  The close-on-exec
+#  status of a file descriptor will be decided according to the value of
+#  C$^F when the corresponding file, pipe, or socket was opened, not
+#  the time of the exec().
+#
+# This documented close-on-exec behaviour is typically implemented in
+# various places (e.g. pp_sys.c) with code something like:
+#
+#  #if defined(HAS_FCNTL)  defined(F_SETFD)
+#  fcntl(fd, F_SETFD, fd  PL_maxsysfd);  /* ensure close-on-exec */
+#  #endif
+#
+# This behaviour, therefore, is only currently implemented for platforms
+# where:
+#
+#  a) HAS_FCNTL and F_SETFD are both defined
+#  b) Integer fds are native OS handles
+#
+# ... which is typically just the Unix-like platforms.
+#
+# Notice that though integer fds are supported by the C runtime library
+# on Windows, they are not native OS handles, and so are not inherited
+# across an exec (though native Windows file handles are).
+
+BEGIN {
+chdir 't' if -d 't';
+@INC = '../lib';
+use Config;
+if (!$Config{'d_fcntl'}) {
+print(1..0 # Skip: fcntl() is not available\n);
+exit(0);
+}
+require './test.pl';
+}
+
+use strict;
+
+$|=1;
+
+my $Is_VMS  = $^O eq 'VMS';
+my $Is_MacOS= $^O eq 'MacOS';
+my $Is_Win32= $^O eq 'MSWin32';
+my $Is_Cygwin   = $^O eq 'cygwin';
+
+# When in doubt, skip.
+skip_all(MacOS)if $Is_MacOS;
+skip_all(VMS)  if $Is_VMS;
+skip_all(cygwin)   if $Is_Cygwin;
+skip_all(Win32)if $Is_Win32;
+
+sub make_tmp_file {
+my ($fname, $fcontents) = @_;
+local *FHTMP;
+open   FHTMP, $fname  or die open  '$fname': $!;
+print  FHTMP $fcontents  or die print '$fname': $!;
+close  FHTMP or die close '$fname': $!;
+}
+
+my $Perl = which_perl();
+my $quote = $Is_VMS || $Is_Win32 ? '' : ';
+
+my $tmperr = 'cloexece.tmp';
+my $tmpfile1   = 'cloexec1.tmp';
+my $tmpfile2   = 'cloexec2.tmp';
+my $tmpfile1_contents  = tmpfile1 line 1\ntmpfile1 line 2\n;
+my $tmpfile2_contents  = tmpfile2 line 1\ntmpfile2 line 2\n;
+make_tmp_file($tmpfile1, $tmpfile1_contents);
+make_tmp_file($tmpfile2, $tmpfile2_contents);
+
+# $Child_prog is the program run by the child that inherits the fd.
+# Note: avoid using ' or  in $Child_prog since it is run with -e
+my $Child_prog = 'CHILD_PROG';
+my $fd = shift;
+print qq{childfd=$fd\n};
+open INHERIT, qq{=$fd} or die qq{open $fd: $!};
+my $line = INHERIT;
+close INHERIT or die qq{close $fd: $!};
+print $line
+CHILD_PROG
+$Child_prog =~ tr/\n//d;
+
+plan(tests = 22);
+
+sub test_not_inherited {
+my $expected_fd = shift;
+ok( -f $tmpfile2, tmpfile '$tmpfile2' exists );
+my $cmd = qq{$Perl -e $quote$Child_prog$quote $expected_fd};
+# Expect 'Bad file descriptor' 

Change 30698: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30698 by [EMAIL PROTECTED] on 2007/03/22 21:42:58

Integrate:
[ 29260]
Subject: Re: [PATCH] New regex syntax omnibus
From: demerphq [EMAIL PROTECTED]
Date: Thu, 9 Nov 2006 17:09:34 +0100
Message-ID: [EMAIL PROTECTED]

[ 29306]
Tidy up Makefile part of #29260 and apply to makefile.mk too

Affected files ...

... //depot/maint-5.8/perl/win32/Makefile#65 integrate
... //depot/maint-5.8/perl/win32/makefile.mk#73 integrate

Differences ...

 //depot/maint-5.8/perl/win32/Makefile#65 (text) 
Index: perl/win32/Makefile
--- perl/win32/Makefile#64~30311~   2007-02-15 03:24:02.0 -0800
+++ perl/win32/Makefile 2007-03-22 14:42:58.0 -0700
@@ -952,8 +952,15 @@
$(X2P) MakePPPort Extensions $(PERLSTATIC)
@echo   Everything is up to date. '$(MAKE_BARE) test' to run test suite.
 
-reonly : .\config.h $(GLOBEXE) $(MINIMOD) $(CONFIGPM) $(UNIDATAFILES) 
$(PERLEXE) \
-   $(X2P) Extensions_reonly
+..\regnodes.h : ..\regcomp.sym
+   cd ..
+   regcomp.pl
+   cd win32
+
+regnodes : ..\regnodes.h
+
+reonly : regnodes .\config.h $(GLOBEXE) $(MINIMOD) $(CONFIGPM) $(UNIDATAFILES) 
\
+   $(PERLEXE) $(X2P) Extensions_reonly
@echo   Perl and 're' are up to date.
 
 $(DYNALOADER)$(o) : $(DYNALOADER).c $(CORE_H) $(EXTDIR)\DynaLoader\dlutils.c
@@ -1366,11 +1373,6 @@
regen.pl
cd win32
 
-regnodes :
-   cd ..
-   regcomp.pl
-   cd win32
-
 test-notty : test-prep
set PERL_SKIP_TTY_TEST=1
cd ..\t

 //depot/maint-5.8/perl/win32/makefile.mk#73 (text) 
Index: perl/win32/makefile.mk
--- perl/win32/makefile.mk#72~30311~2007-02-15 03:24:02.0 -0800
+++ perl/win32/makefile.mk  2007-03-22 14:42:58.0 -0700
@@ -1017,7 +1017,12 @@
$(RIGHTMAKE) $(MINIMOD) $(CONFIGPM) $(UNIDATAFILES) $(PERLEXE)  \
$(X2P) MakePPPort Extensions $(PERLSTATIC)
 
-reonly : .\config.h $(GLOBEXE) $(MINIPERL) $(MK2)  \
+..\regnodes.h : ..\regcomp.sym
+   cd ..  regcomp.pl  cd win32
+
+regnodes : ..\regnodes.h
+
+reonly : regnodes .\config.h $(GLOBEXE) $(MINIPERL) $(MK2) \
$(RIGHTMAKE) $(MINIMOD) $(CONFIGPM) $(UNIDATAFILES) $(PERLEXE)  \
$(X2P) Extensions_reonly
 
@@ -1565,9 +1570,6 @@
 regen :
cd ..  regen.pl  cd win32
 
-regnodes :
-   cd ..  regcomp.pl  cd win32
-
 test-notty : test-prep
set PERL_SKIP_TTY_TEST=1  \
cd ..\t  $(PERLEXE) -I.\lib harness $(TEST_SWITCHES) $(TEST_FILES)
End of Patch.


Change 30699: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30699 by [EMAIL PROTECTED] on 2007/03/22 21:48:18

Integrate:
[ 28904]
Subject: [PATCH] Minor re 'Debug' tweaks, also fix a bug in dumping 
certain patterns.
From: demerphq [EMAIL PROTECTED]
Date: Fri, 29 Sep 2006 17:39:16 +0200
Message-ID: [EMAIL PROTECTED]

[ 29308]
Subject: [perl #36909] $^R undefined on matches involving backreferences
From: yves orton via RT [EMAIL PROTECTED]
Date: Nov 17, 2006 4:07 PM

[ 29323]
Extend the test-reonly make target on windows (Yves Orton)

[ 29355]
Update makefile.mk as per Makefile w.r.t. #29308 and #29323

Affected files ...

... //depot/maint-5.8/perl/win32/Makefile#66 integrate
... //depot/maint-5.8/perl/win32/makefile.mk#74 integrate

Differences ...

 //depot/maint-5.8/perl/win32/Makefile#66 (text) 
Index: perl/win32/Makefile
--- perl/win32/Makefile#65~30698~   2007-03-22 14:42:58.0 -0700
+++ perl/win32/Makefile 2007-03-22 14:48:18.0 -0700
@@ -498,6 +498,7 @@
 # we add LIBC here, since we may be using PerlCRT.dll
 LIBFILES   = $(LIBBASEFILES) $(LIBC)
 
+#EXTRACFLAGS   = -nologo -GF -W4 -wd4127 -wd4706
 EXTRACFLAGS= -nologo -GF -W3
 CFLAGS = $(EXTRACFLAGS) $(INCLUDES) $(DEFINES) $(LOCDEFS) \
$(PCHFLAGS) $(OPTIMIZE)
@@ -1140,14 +1141,17 @@
 
 
#---
 Extensions: buildext.pl $(PERLDEP) $(CONFIGPM)
+   $(XCOPY) ..\*.h $(COREDIR)\*.*
$(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) --dynamic
$(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext --dynamic
 
 Extensions_reonly: buildext.pl $(PERLDEP) $(CONFIGPM)
+   $(XCOPY) ..\*.h $(COREDIR)\*.*
$(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) --dynamic 
+re
$(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext --dynamic +re
 
 Extensions_static : buildext.pl $(PERLDEP) $(CONFIGPM)
+   $(XCOPY) ..\*.h $(COREDIR)\*.*
$(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) --static
$(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext --static
$(MINIPERL) -I..\lib buildext.pl --list-static-libs  Extensions_static
@@ -1365,7 +1369,7 @@
$(XCOPY) $(PERLDLL) ..\t\$(NULL)
$(XCOPY) $(GLOBEXE) ..\t\$(NULL)
cd ..\t
-   $(PERLEXE) -I..\lib harness $(OPT) -re \bpat\b \breg
+   $(PERLEXE) -I..\lib harness $(OPT) -re \bpat\b \breg \bre\b \bsubst 
\brxcode $(EXTRA)
cd ..\win32

 regen :

 //depot/maint-5.8/perl/win32/makefile.mk#74 (text) 
Index: perl/win32/makefile.mk
--- perl/win32/makefile.mk#73~30698~2007-03-22 14:42:58.0 -0700
+++ perl/win32/makefile.mk  2007-03-22 14:48:18.0 -0700
@@ -1564,7 +1564,7 @@
$(XCOPY) $(PERLDLL) ..\t\$(NULL)
$(XCOPY) $(GLOBEXE) ..\t\$(NULL)
cd ..\t  \
-   $(PERLEXE) -I..\lib harness $(OPT) -re \bpat\b \breg \bre\b $(EXTRA)  
\
+   $(PERLEXE) -I..\lib harness $(OPT) -re \bpat\b \breg \bre\b \bsubst 
\brxcode $(EXTRA)  \
cd ..\win32
 
 regen :
End of Patch.


Change 30700: Can use memEQ instead of strnEQ in CHECK_WORD()

2007-03-22 Thread Nicholas Clark
Change 30700 by [EMAIL PROTECTED] on 2007/03/22 22:21:54

Can use memEQ instead of strnEQ in CHECK_WORD()

Affected files ...

... //depot/perl/regcomp.c#566 edit

Differences ...

 //depot/perl/regcomp.c#566 (text) 
Index: perl/regcomp.c
--- perl/regcomp.c#565~30678~   2007-03-22 02:01:37.0 -0700
+++ perl/regcomp.c  2007-03-22 15:21:54.0 -0700
@@ -4956,7 +4956,7 @@
 
 /* this idea is borrowed from STR_WITH_LEN in handy.h */
 #define CHECK_WORD(s,v,l)  \
-(((sizeof(s)-1)==(l))  (strnEQ(start_verb, (s ), (sizeof(s)-1
+(((sizeof(s)-1)==(l))  (memEQ(start_verb, (s ), (sizeof(s)-1
 
 STATIC regnode *
 S_reg(pTHX_ RExC_state_t *pRExC_state, I32 paren, I32 *flagp,U32 depth)
End of Patch.


Change 30701: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30701 by [EMAIL PROTECTED] on 2007/03/22 22:25:21

Integrate:
[ 29359]
More safety in free()s

[ 30389]
Subject: [PATCH] perlio.c (PerlIO_tmpfile): fix memory leak
From: Alexey Tourbin [EMAIL PROTECTED]
Date: Sat, 24 Feb 2007 14:47:35 +0300
Message-ID: [EMAIL PROTECTED]

[ 30398]
Subject: [perl #41560] [PATCH] crash in Perl_vmess when GvIOp is null 
From: Devin Heitmueller (via RT) [EMAIL PROTECTED]
Date: Tue, 20 Feb 2007 16:38:20 -0800
Message-ID: [EMAIL PROTECTED]

[ 30442]
Don't crash if the symbol table entry for ISA isn't a typeglob.

[ 30443]
More assertion failures, found by auditing the code.

[ 30448]
Add a volatile modifier to avoid possible cloberring by longjmp,
as the compiler used by Jerry D. Hedden warns.

[ 30452]
As the test is about the parser, not actually running the code, better
to avoid running STDOUT rather than run it with warnings disabled.

[ 30513]
Need to extend the stack when using warn() without
an argument (this fixes bug #41716)

[ 30560]
Need a SPAGAIN here because the stack pointer might have
moved when evaluating a tied hash in scalar context.

[ 30577]
use a fresh stack when loading Errno.pm etc.
Stops 'use vars qw($!)' in lib/vars.t segfaulting.
(This can be reduced to 'my $sym = !; *$sym = \$$sym')

Affected files ...

... //depot/maint-5.8/perl/gv.c#104 integrate
... //depot/maint-5.8/perl/op.c#208 integrate
... //depot/maint-5.8/perl/perl.c#208 integrate
... //depot/maint-5.8/perl/perlio.c#110 integrate
... //depot/maint-5.8/perl/pp_hot.c#136 integrate
... //depot/maint-5.8/perl/pp_sys.c#146 integrate
... //depot/maint-5.8/perl/t/op/gv.t#9 integrate
... //depot/maint-5.8/perl/toke.c#170 integrate
... //depot/maint-5.8/perl/universal.c#65 integrate
... //depot/maint-5.8/perl/util.c#148 integrate

Differences ...

 //depot/maint-5.8/perl/gv.c#104 (text) 
Index: perl/gv.c
--- perl/gv.c#103~30480~2007-03-05 15:40:56.0 -0800
+++ perl/gv.c   2007-03-22 15:25:21.0 -0700
@@ -359,7 +359,7 @@
 }
 
 gvp = (GV**)hv_fetchs(stash, ISA, FALSE);
-av = (gvp  (gv = *gvp)  gv != (GV*)PL_sv_undef) ? GvAV(gv) : NULL;
+av = (gvp  (gv = *gvp)  isGV_with_GP(gv)) ? GvAV(gv) : NULL;
 
 /* create and re-create @.*::SUPER::ISA on demand */
 if (!av || !SvMAGIC(av)) {
@@ -371,7 +371,7 @@
packlen -= 7;
basestash = gv_stashpvn(hvname, packlen, GV_ADD);
gvp = (GV**)hv_fetchs(basestash, ISA, FALSE);
-   if (gvp  (gv = *gvp) != (GV*)PL_sv_undef  (av = GvAV(gv))) {
+   if (gvp  (gv = *gvp)  isGV_with_GP(gv)  (av = GvAV(gv))) {
gvp = (GV**)hv_fetchs(stash, ISA, TRUE);
if (!gvp || !(gv = *gvp))
Perl_croak(aTHX_ Cannot create %s::ISA, hvname);
@@ -677,11 +677,12 @@
 
 if (!stash || !(gv_fetchmethod(stash, TIEHASH))) {
dSP;
-   PUTBACK;
ENTER;
save_scalar(gv); /* keep the value of $! */
+   PUSHSTACKi(PERLSI_MAGIC);
 Perl_load_module(aTHX_ PERL_LOADMOD_NOIMPORT,
  newSVpvs(Errno), NULL);
+   POPSTACK;
LEAVE;
SPAGAIN;
stash = gv_stashpvs(Errno, 0);

 //depot/maint-5.8/perl/op.c#208 (text) 
Index: perl/op.c
--- perl/op.c#207~30632~2007-03-19 04:54:02.0 -0700
+++ perl/op.c   2007-03-22 15:25:21.0 -0700
@@ -516,6 +516,7 @@
 S_cop_free(pTHX_ COP* cop)
 {
 Safefree(cop-cop_label);   /* FIXME: treaddead ??? */
+cop-cop_label = NULL;
 CopFILE_free(cop);
 CopSTASH_free(cop);
 if (! specialWARN(cop-cop_warnings))
@@ -2726,6 +2727,7 @@
bits = 8;
 
Safefree(cPVOPo-op_pv);
+   cPVOPo-op_pv = NULL;
 
swash = (SV*)swash_init(utf8, , listsv, bits, none);
 #ifdef USE_ITHREADS
@@ -4198,7 +4200,7 @@
/* for XSUBs CvFILE point directly to static memory; __FILE__ */
Safefree(CvFILE(cv));
 }
-CvFILE(cv) = 0;
+CvFILE(cv) = NULL;
 #endif
 
 if (!CvISXSUB(cv)  CvROOT(cv)) {

 //depot/maint-5.8/perl/perl.c#208 (text) 
Index: perl/perl.c
--- perl/perl.c#207~30480~  2007-03-05 15:40:56.0 -0800
+++ perl/perl.c 2007-03-22 15:25:21.0 -0700
@@ -5253,7 +5253,7 @@
 Perl_call_list(pTHX_ I32 oldscope, AV *paramList)
 {
 SV *atsv;
-const line_t oldline = PL_curcop ? CopLINE(PL_curcop) : 0;
+volatile const line_t oldline = PL_curcop ? CopLINE(PL_curcop) : 0;
 CV *cv;
 STRLEN len;
 int ret;

 //depot/maint-5.8/perl/perlio.c#110 (text) 
Index: perl/perlio.c
--- perl/perlio.c#109~30314~2007-02-15 05:06:29.0 -0800
+++ perl/perlio.c   2007-03-22 15:25:21.0 -0700

Change 30703: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30703 by [EMAIL PROTECTED] on 2007/03/22 23:14:35

Integrate:
[ 30345]
newHV doesn't need to turn off POK or NOK, as they will default to not
being set.

[ 30659]
Don't try to set the NV on a typeglob-in-action. Should cure bug
41920.

Affected files ...

... //depot/maint-5.8/perl/hv.c#114 integrate
... //depot/maint-5.8/perl/sv.c#349 integrate

Differences ...

 //depot/maint-5.8/perl/hv.c#114 (text) 
Index: perl/hv.c
--- perl/hv.c#113~30668~2007-03-21 12:29:38.0 -0700
+++ perl/hv.c   2007-03-22 16:14:35.0 -0700
@@ -1322,8 +1322,6 @@
 register XPVHV* xhv;
 HV * const hv = (HV*)newSV_type(SVt_PVHV);
 xhv = (XPVHV*)SvANY(hv);
-SvPOK_off(hv);
-SvNOK_off(hv);
 #ifndef NODEFAULT_SHAREKEYS
 HvSHAREKEYS_on(hv); /* key-sharing on by default */
 #endif

 //depot/maint-5.8/perl/sv.c#349 (text) 
Index: perl/sv.c
--- perl/sv.c#348~30692~2007-03-22 10:55:41.0 -0700
+++ perl/sv.c   2007-03-22 16:14:35.0 -0700
@@ -1314,7 +1314,8 @@
 * NV slot, but the new one does, then we need to initialise the
 * freshly created NV slot with whatever the correct bit pattern is
 * for 0.0  */
-   if (old_type_details-zero_nv  !bodies_by_type[new_type].zero_nv)
+   if (old_type_details-zero_nv  !new_type_details-zero_nv
+!isGV_with_GP(sv))
SvNV_set(sv, 0);
 #endif
 
End of Patch.


Change 30702: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30702 by [EMAIL PROTECTED] on 2007/03/22 23:01:23

Integrate:
[ 29227]
Use $HOME/localperl as default prefix for installing perl
in the terse installation instructions in README.

[ 30278]
Subject: Re: [PATCH] Document that m//k works
From: demerphq [EMAIL PROTECTED]
Date: Tue, 13 Feb 2007 22:04:54 +0100
Message-ID: [EMAIL PROTECTED]

[ 30484]
Doc patch about PerlIO::encoding:

Subject: [PATCH] Re: 'Unknown PerlIO layer encoding...' message
From: Tels [EMAIL PROTECTED]
Date: Fri, 2 Mar 2007 11:31:39 +
Message-Id: [EMAIL PROTECTED]

[ 30525]
Mention Perl::Unsafe::Signals in the core docs en passant.

[ 30554]
warn() without args doesn't take a default message in $_, but in $@

[ 30575]
Subject: [PATCH] perlfunc.pod (ref results), perlop.pod (qr// result) 
From: Wolfgang Laun [EMAIL PROTECTED]
Date: Wed, 14 Mar 2007 07:56:45 +0100
Message-ID: [EMAIL PROTECTED]

[ 30596]
Don't mention DynaLoader.a in INSTALL,
since it doesn't exist anymore

[ 30643]
Subject: Re: Composing @INC from PERL5LIB
From: [EMAIL PROTECTED] (Andreas J. Koenig)
Date: Mon, 19 Mar 2007 23:35:10 +0100
Message-ID: [EMAIL PROTECTED]

[ 30645]
More adjustments to the PERL5LIB docs by Rick
Delaney and myself

[ 30646]
Better wording for the return value of select()
(bug #41907)

[ 30648]
More nits in the PERL5LIB docs, suggested by Andreas.

[ 30649]
Subject: [PATCH] my email address changed
From: Michael Stevens [EMAIL PROTECTED]
Date: Tue, 20 Mar 2007 15:49:12 +
Message-ID: [EMAIL PROTECTED]

[ 30685]
Remove references to perlcc from the core docs.

[ 30686]
Fix a broken link and a meaningless phrase in perldebguts

[ 30688]
Misc. L fixes in core docs : don't link to man pages;
provide full urls when linking to web sites.

Affected files ...

... //depot/maint-5.8/perl/AUTHORS#46 integrate
... //depot/maint-5.8/perl/INSTALL#46 integrate
... //depot/maint-5.8/perl/README#10 integrate
... //depot/maint-5.8/perl/pod/perldebguts.pod#6 integrate
... //depot/maint-5.8/perl/pod/perldiag.pod#98 integrate
... //depot/maint-5.8/perl/pod/perlfunc.pod#99 integrate
... //depot/maint-5.8/perl/pod/perlipc.pod#23 integrate
... //depot/maint-5.8/perl/pod/perllocale.pod#5 integrate
... //depot/maint-5.8/perl/pod/perlmod.pod#13 integrate
... //depot/maint-5.8/perl/pod/perlop.pod#35 integrate
... //depot/maint-5.8/perl/pod/perlpacktut.pod#5 integrate
... //depot/maint-5.8/perl/pod/perlre.pod#19 integrate
... //depot/maint-5.8/perl/pod/perlrun.pod#63 integrate
... //depot/maint-5.8/perl/pod/perlutil.pod#3 integrate
... //depot/maint-5.8/perl/pod/perlvar.pod#45 integrate

Differences ...

 //depot/maint-5.8/perl/AUTHORS#46 (text) 
Index: perl/AUTHORS
--- perl/AUTHORS#45~30479~  2007-03-05 15:13:13.0 -0800
+++ perl/AUTHORS2007-03-22 16:01:23.0 -0700
@@ -587,7 +587,7 @@
 Michael Mahan  [EMAIL PROTECTED]
 Michael Schroeder  [EMAIL PROTECTED]
 Michael Somos  [EMAIL PROTECTED]
-Michael Stevens[EMAIL PROTECTED]
+Michael Stevens[EMAIL PROTECTED]
 Michele Sardo
 Mik Firestone  [EMAIL PROTECTED]
 Mike Fletcher  [EMAIL PROTECTED]

 //depot/maint-5.8/perl/INSTALL#46 (text) 
Index: perl/INSTALL
--- perl/INSTALL#45~30470~  2007-03-05 12:02:51.0 -0800
+++ perl/INSTALL2007-03-22 16:01:23.0 -0700
@@ -535,8 +535,7 @@
 
 Currently, for most systems, the main perl executable is built by
 linking the perl library libperl.a with perlmain.o, your static
-extensions (usually just DynaLoader.a) and various extra libraries,
-such as -lm.
+extensions, and various extra libraries, such as -lm.
 
 On some systems that support dynamic loading, it may be possible to
 replace libperl.a with a shared libperl.so.  If you anticipate building

 //depot/maint-5.8/perl/README#10 (text) 
Index: perl/README
--- perl/README#9~30470~2007-03-05 12:02:51.0 -0800
+++ perl/README 2007-03-22 16:01:23.0 -0700
@@ -30,10 +30,13 @@
 If you're using a relatively modern operating system and want to
 install this version of Perl locally, run the following commands:
 
-  ./Configure -des -Dprefix=/opt/foo
+  ./Configure -des -Dprefix=$HOME/localperl
   make test
   make install
 
+This will configure and compile perl for your platform, run the regression
+tests, and install perl in a subdirectory localperl of your home directory.
+
 If you run into 

Change 30705: Integrate:

2007-03-22 Thread Nicholas Clark
Change 30705 by [EMAIL PROTECTED] on 2007/03/22 23:48:47

Integrate:
[ 30091]
Better dump reporting of PVBMs.

[ 30366]
Subject: [PATCH] dump.c: format fixes
From: [EMAIL PROTECTED] (Jarkko Hietaniemi)
Date: Tue, 20 Feb 2007 03:00:50 +0200 (EET)
Message-Id: [EMAIL PROTECTED]

Affected files ...

... //depot/maint-5.8/perl/dump.c#80 integrate

Differences ...

 //depot/maint-5.8/perl/dump.c#80 (text) 
Index: perl/dump.c
--- perl/dump.c#79~30302~   2007-02-14 14:00:02.0 -0800
+++ perl/dump.c 2007-03-22 16:48:47.0 -0700
@@ -1532,6 +1532,12 @@
if (nest  maxnest  (CvCLONE(sv) || CvCLONED(sv)))
do_sv_dump(level+1, file, (SV*)CvOUTSIDE(sv), nest+1, maxnest, 
dumpops, pvlim);
break;
+case SVt_PVBM:
+   Perl_dump_indent(aTHX_ level, file,   FLAGS = %u\n, (U8)BmFLAGS(sv));
+   Perl_dump_indent(aTHX_ level, file,   RARE = %u\n, (U8)BmRARE(sv));
+   Perl_dump_indent(aTHX_ level, file,   PREVIOUS = %UVuf\n, 
(UV)BmPREVIOUS(sv));
+   Perl_dump_indent(aTHX_ level, file,   USEFUL = %IVdf\n, 
(IV)BmUSEFUL(sv));
+   break;
 case SVt_PVGV:
Perl_dump_indent(aTHX_ level, file,   NAME = \%s\\n, GvNAME(sv));
Perl_dump_indent(aTHX_ level, file,   NAMELEN = %IVdf\n, 
(IV)GvNAMELEN(sv));
End of Patch.


Change 30704: Implement BmFLAGS() for 5.8.x. Not exactly pretty.

2007-03-22 Thread Nicholas Clark
Change 30704 by [EMAIL PROTECTED] on 2007/03/22 23:48:39

Implement BmFLAGS() for 5.8.x. Not exactly pretty.
(And the irony is that the C structure always had enough space for a
member for this 1 byte value)

Affected files ...

... //depot/maint-5.8/perl/sv.h#82 edit

Differences ...

 //depot/maint-5.8/perl/sv.h#82 (text) 
Index: perl/sv.h
--- perl/sv.h#81~30469~ 2007-03-05 11:20:16.0 -0800
+++ perl/sv.h   2007-03-22 16:48:39.0 -0700
@@ -1020,13 +1020,19 @@
 }  \
 } STMT_END
 
-#define BmRARE(sv) ((XPVBM*)  SvANY(sv))-xbm_rare
-#define BmUSEFUL(sv)   ((XPVBM*)  SvANY(sv))-xbm_useful
-#define BmPREVIOUS(sv) ((XPVBM*)  SvANY(sv))-xbm_previous
 
 #define PERL_FBM_TABLE_OFFSET 2/* Number of bytes between EOS and 
table */
 #define PERL_FBM_FLAGS_OFFSET_FROM_TABLE -1
 
+#define BmFLAGS(sv)((SvVALID(sv)  SvPOK(sv)\
+ (SvLEN(sv)  (SvCUR(sv) + PERL_FBM_TABLE_OFFSET))) \
+? SvPVX(sv)[SvCUR(sv) + PERL_FBM_TABLE_OFFSET   \
++ PERL_FBM_FLAGS_OFFSET_FROM_TABLE] \
+: 0)
+#define BmRARE(sv) ((XPVBM*)  SvANY(sv))-xbm_rare
+#define BmUSEFUL(sv)   ((XPVBM*)  SvANY(sv))-xbm_useful
+#define BmPREVIOUS(sv) ((XPVBM*)  SvANY(sv))-xbm_previous
+
 #define FmLINES(sv)((XPVFM*)  SvANY(sv))-xfm_lines
 
 #define LvTYPE(sv) ((XPVLV*)  SvANY(sv))-xlv_type
End of Patch.


Change 30707: Additional test file edits needed for Pod-Simple-3.05 that couldn't

2007-03-22 Thread Steve Peters
Change 30707 by [EMAIL PROTECTED] on 2007/03/23 01:47:41

Additional test file edits needed for Pod-Simple-3.05 that couldn't
be included due to the integrates being performed in the previous
change.

Affected files ...

... //depot/perl/lib/Pod/Simple/t/htmlbat.t#2 edit
... //depot/perl/lib/Pod/Simple/t/render.t#3 edit
... //depot/perl/lib/Pod/Simple/t/search10.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search12.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search20.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search22.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search25.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search26.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search27.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search28.t#2 edit
... //depot/perl/lib/Pod/Simple/t/search29.t#2 edit

Differences ...

 //depot/perl/lib/Pod/Simple/t/htmlbat.t#2 (text) 
Index: perl/lib/Pod/Simple/t/htmlbat.t
--- perl/lib/Pod/Simple/t/htmlbat.t#1~30706~2007-03-22 18:43:11.0 
-0700
+++ perl/lib/Pod/Simple/t/htmlbat.t 2007-03-22 18:47:41.0 -0700
@@ -1,3 +1,4 @@
+# Testing HTMLBatch
 BEGIN {
 if($ENV{PERL_CORE}) {
 chdir 't';
@@ -33,7 +34,7 @@
   next unless -e $t_maybe;
 
   $t_dir = $t_maybe;
-  $corpus_dir = File::Spec-catdir( $t_maybe, 'test_lib' );
+  $corpus_dir = File::Spec-catdir( $t_maybe, 'testlib1' );
   next unless -e $corpus_dir;
   last;
 }

 //depot/perl/lib/Pod/Simple/t/render.t#3 (text) 
Index: perl/lib/Pod/Simple/t/render.t
--- perl/lib/Pod/Simple/t/render.t#2~26341~ 2005-12-13 04:17:57.0 
-0800
+++ perl/lib/Pod/Simple/t/render.t  2007-03-22 18:47:41.0 -0700
@@ -1,7 +1,9 @@
 BEGIN {
-chdir 't';
 if($ENV{PERL_CORE}) {
+chdir 't';
 @INC = '../lib';
+} else {
+push @INC, '../lib';
 }
 }
 
@@ -20,6 +22,8 @@
 $Pod::Simple::Text::FREAKYMODE = 1;
 use Pod::Simple::TiedOutFH ();
 
+chdir 't' unless $ENV{PERL_CORE};
+
 sub source_path {
 my $file = shift;
 if ($ENV{PERL_CORE}) {
@@ -38,7 +42,7 @@
   junk1.pod,
   junk2.pod,
   perlcyg.pod,
-  perlfaq3.pod,
+  perlfaq.pod,
   perlvar.pod,
 ) {
 
@@ -50,7 +54,7 @@
 
   my @out;
   my $precooked = source_path($file);
-  $precooked =~ s\.pod_out.txts;
+  $precooked =~ s\.podo.txts;
   unless(-e $precooked) {
 ok 0;
 print # But $precooked doesn't exist!!\n;

 //depot/perl/lib/Pod/Simple/t/search10.t#2 (text) 
Index: perl/lib/Pod/Simple/t/search10.t
--- perl/lib/Pod/Simple/t/search10.t#1~30706~   2007-03-22 18:43:11.0 
-0700
+++ perl/lib/Pod/Simple/t/search10.t2007-03-22 18:47:41.0 -0700
@@ -43,9 +43,9 @@
 }
 
 my $here;
-if( -e ($here = source_path('test_lib'))) {
+if( -e ($here = source_path('testlib1'))) {
   #
-} elsif(-e ($here = File::Spec-catdir($cwd, 't', 'test_lib'))) {
+} elsif(-e ($here = File::Spec-catdir($cwd, 't', 'testlib1'))) {
   #
 } else {
   die Can't find the test corpus;
@@ -68,12 +68,12 @@
 
 {
 my $names = join |, sort values %$where2name;
-ok $names, 
Blorm|Zonk::Pronk|hink_honk::Glunk|hink_honk::Vliff|perlfliff|perlthang|squaa|squaa::Glunk|squaa::Vliff|zikzik;
+ok $names, 
Blorm|Zonk::Pronk|hinkhonk::Glunk|hinkhonk::Vliff|perlflif|perlthng|squaa|squaa::Glunk|squaa::Vliff|zikzik;
 }
 
 {
 my $names = join |, sort keys %$name2where;
-ok $names, 
Blorm|Zonk::Pronk|hink_honk::Glunk|hink_honk::Vliff|perlfliff|perlthang|squaa|squaa::Glunk|squaa::Vliff|zikzik;
+ok $names, 
Blorm|Zonk::Pronk|hinkhonk::Glunk|hinkhonk::Vliff|perlflif|perlthng|squaa|squaa::Glunk|squaa::Vliff|zikzik;
 }
 
 ok( ($name2where-{'squaa'} || 'huh???'), '/squaa\.pm$/');

 //depot/perl/lib/Pod/Simple/t/search12.t#2 (text) 
Index: perl/lib/Pod/Simple/t/search12.t
--- perl/lib/Pod/Simple/t/search12.t#1~30706~   2007-03-22 18:43:11.0 
-0700
+++ perl/lib/Pod/Simple/t/search12.t2007-03-22 18:47:41.0 -0700
@@ -36,9 +36,9 @@
 }
 
 my $here;
-if( -e ($here = source_path('test_lib'))) {
+if( -e ($here = source_path('testlib1'))) {
   chdir $here;
-} elsif(-e ($here = File::Spec-catdir($cwd, 't', 'test_lib'))) {
+} elsif(-e ($here = File::Spec-catdir($cwd, 't', 'testlib1'))) {
   chdir $here;
 } else {
   die Can't find the test corpus;
@@ -61,12 +61,12 @@
 
 {
 my $names = join |, sort values %$where2name;
-ok $names, 
Blorm|Zonk::Pronk|hink_honk::Glunk|hink_honk::Vliff|perlfliff|perlthang|squaa|squaa::Glunk|squaa::Vliff|zikzik;
+ok $names, 
Blorm|Zonk::Pronk|hinkhonk::Glunk|hinkhonk::Vliff|perlflif|perlthng|squaa|squaa::Glunk|squaa::Vliff|zikzik;
 }
 
 {
 my $names = join |, sort keys %$name2where;
-ok $names, 
Blorm|Zonk::Pronk|hink_honk::Glunk|hink_honk::Vliff|perlfliff|perlthang|squaa|squaa::Glunk|squaa::Vliff|zikzik;
+ok $names, 
Blorm|Zonk::Pronk|hinkhonk::Glunk|hinkhonk::Vliff|perlflif|perlthng|squaa|squaa::Glunk|squaa::Vliff|zikzik;
 }
 
 ok( ($name2where-{'squaa'} || 'huh???'), '/squaa\.pm$/');

 //depot/perl/lib/Pod/Simple/t/search20.t#2 (text) 
Index: 

Change 30708: [PATCH] fix instalhtml and Pod::HTML issues.

2007-03-22 Thread Steve Peters
Change 30708 by [EMAIL PROTECTED] on 2007/03/23 01:54:54

[PATCH] fix instalhtml and Pod::HTML issues.
From: demerphq [EMAIL PROTECTED]
Date: Thu, 22 Mar 2007 19:42:54 +0100
Message-ID: [EMAIL PROTECTED]

Just the changes to installhtml and Pod::HTML in this patch.

Affected files ...

... //depot/perl/installhtml#26 edit
... //depot/perl/lib/Pod/Html.pm#90 edit

Differences ...

 //depot/perl/installhtml#26 (xtext) 
Index: perl/installhtml
--- perl/installhtml#25~25560~  2005-09-21 14:10:50.0 -0700
+++ perl/installhtml2007-03-22 18:54:54.0 -0700
@@ -43,7 +43,7 @@
 =item B--podpath POD search path
 
 The list of directories to search for .pod and .pm files to be converted.
-Default is `podroot/.'.
+Default is 'podroot/.'.
 
 =item B--recurse recurse on subdirectories
 
@@ -58,7 +58,7 @@
 =item B--htmlroot URL base directory
 
 The base directory which all resulting HTML files will be visible at in
-a URL.  The default is `/'.
+a URL.  The default is '/'.
 
 =item B--splithead POD files to split on =head directive
 
@@ -75,7 +75,7 @@
 
 =item B--splitpod Directory containing the splitpod program
 
-The directory containing the splitpod program. The default is `podroot/pod'.
+The directory containing the splitpod program. The default is 'podroot/pod'.
 
 =item B--libpods library PODs for LEltEgt links
 
@@ -556,8 +556,8 @@
 
# check if a .pm files exists too
if (grep($_ eq $pod, @pmlist)) {
-   print  $0: Warning both `$podroot/$pod.pod' and 
-   . `$podroot/$pod.pm' exist, using pod\n;
+   print  $0: Warning both '$podroot/$pod.pod' and 
+   . '$podroot/$pod.pm' exist, using pod\n;
push(@ignore, $pod.pm);
}
runpod2html($pod.pod, $doindex);

 //depot/perl/lib/Pod/Html.pm#90 (text) 
Index: perl/lib/Pod/Html.pm
--- perl/lib/Pod/Html.pm#89~30681~  2007-03-22 02:28:15.0 -0700
+++ perl/lib/Pod/Html.pm2007-03-22 18:54:54.0 -0700
@@ -1129,8 +1129,9 @@
 
 sub emit_item_tag($$$){
 my( $otext, $text, $compact ) = @_;
-my $item = fragment_id( $text , -generate);
-
+my $item = fragment_id( depod($text) , -generate);
+Carp::confess(Undefined fragment '$text' (.depod($text).) from 
fragment_id() in emit_item_tag() in $Podfile)
+if !defined $item;
 $EmittedItem = $item;
 ### print STDERR emit_item_tag=$item ($text)\n;
 
@@ -1186,7 +1187,7 @@
 # all the list variants:
 if( $text =~ /\A\*/ ){ # bullet
 $emitted = emit_li( 'ul' );
-if ($text =~ /\A\*\s+(.+)\Z/s ) { # with additional text
+if ($text =~ /\A\*\s+(\S.*)\Z/s ) { # with additional text
 my $tag = $1;
 $otext =~ s/\A\*\s+//;
 emit_item_tag( $otext, $tag, 1 );
@@ -1194,7 +1195,7 @@
 
 } elsif( $text =~ /\A\d+/ ){ # numbered list
 $emitted = emit_li( 'ol' );
-if ($text =~ /\A(?\d+\.?)\s*(.+)\Z/s ) { # with additional text
+if ($text =~ /\A(?\d+\.?)\s*(\S.*)\Z/s ) { # with additional text
 my $tag = $1;
 $otext =~ s/\A\d+\.?\s*//;
 emit_item_tag( $otext, $tag, 1 );
@@ -1300,8 +1301,8 @@
 sub process_end {
 my($whom, $text) = @_;
 $whom = lc($whom);
-if ($Begin_Stack[-1] ne $whom ) {
-   die Unmatched begin/end at chunk $Paragraph\n
+if (!defined $Begin_Stack[-1] or $Begin_Stack[-1] ne $whom ) {
+   Carp::confess(Unmatched begin/end at chunk $Paragraph in pod 
$Podfile\n)
 }
 pop( @Begin_Stack );
 }
@@ -1494,8 +1495,8 @@
 #
 
 sub process_text1($$;$$);
-sub pattern ($) { $_[0] ? '[^\S\n]+'.('' x ($_[0] + 1)) : '' }
-sub closing ($) { local($_) = shift; (defined  s/\s+$//) ? length : 0 }
+sub pattern ($) { $_[0] ? '\s+'.('' x ($_[0] + 1)) : '' }
+sub closing ($) { local($_) = shift; (defined  s/\s+\z//) ? length : 0 }
 
 sub process_text {
 return if $Ignore;
@@ -1516,7 +1517,7 @@
(?=[^[:alpha:]])   # Make sure this is not an URL already
(RFC\s*([0-9]{1,5}))(?![0-9]) # max 5 digits
 }
-{a href=http://www.ietf.org/rfc/rfc$3.txt; class=rfc$1/a}gx;
+{a href=http://www.ietf.org/rfc/rfc$2.txt; class=rfc$1/a}gx;
 
 $text;
 }
@@ -1596,7 +1597,11 @@
# check for link patterns
if( $par =~ m{^([^/]+?)/(?!)(.*?)$} ){ # name/ident
 # we've got a name/ident (no quotes)
-( $page, $ident ) = ( $1, $2 );
+if (length $2) {
+( $page, $ident ) = ( $1, $2 );
+} else {
+( $page, $section ) = ( $1, $2 );
+}
 ### print STDERR -- L$par to page $page, ident $ident\n;
 
} elsif( $par =~ m{^(.*?)/?(.*?)?$} ){ # [name]/section
@@ -1684,11 +1689,11 @@
 
 } elsif( $func eq 'X' ){
# X - ignore
-   $$rstr =~ s/^[^]*//;
-
+   warn $0: $Podfile: invalid X in paragraph $Paragraph.\n
+   unless $$rstr =~ s/^[^]*// or 

Change 30709: Perforce appararently didn't like integrating this file, since

2007-03-22 Thread Steve Peters
Change 30709 by [EMAIL PROTECTED] on 2007/03/23 02:06:06

Perforce appararently didn't like integrating this file, since
I had done it twice.  It looks like an add will have to do instead.

Affected files ...

... //depot/perl/lib/Pod/Simple/t/perlvaro.txt#1 add

Differences ...

 //depot/perl/lib/Pod/Simple/t/perlvaro.txt#1 (text) 
Index: perl/lib/Pod/Simple/t/perlvaro.txt
--- /dev/null   2007-03-19 09:41:43.516454971 -0700
+++ perl/lib/Pod/Simple/t/perlvaro.txt  2007-03-22 19:06:06.0 -0700
@@ -0,0 +1,406 @@
+NAME
+perlvar - Perl predefined variables
+DESCRIPTION
+Predefined Names
+The following names have special meaning to Perl. Most punctuation names have 
reasonable mnemonics, or analogs in the shells. Nevertheless, if you wish to 
use long variable names, you need only say
+use English;
+at the top of your program. This will alias all the short names to the long 
names in the current package. Some even have medium names, generally borrowed 
from awk.
+If you don't mind the performance hit, variables that depend on the currently 
selected filehandle may instead be set by calling an appropriate object method 
on the IO::Handle object. (Summary lines below for this contain the word 
HANDLE.) First you must say
+use IO::Handle;
+after which you may use either
+method HANDLE EXPR
+or more safely,
+HANDLE-method(EXPR)
+Each method returns the old value of the IO::Handle attribute. The methods 
each take an optional EXPR, which if supplied specifies the new value for the 
IO::Handle attribute in question. If not supplied, most methods do nothing to 
the current value--except for autoflush(), which will assume a 1 for you, just 
to be different. Because loading in the IO::Handle class is an expensive 
operation, you should learn how to use the regular built-in variables.
+A few of these variables are considered read-only. This means that if you 
try to assign to this variable, either directly or indirectly through a 
reference, you'll raise a run-time exception.
+The following list is ordered by scalar variables first, then the arrays, then 
the hashes.
+$ARG
+$_
+The default input and pattern-searching space. The following pairs are 
equivalent:
+while () {...}# equivalent only in while!
+while (defined($_ = )) {...}
+/^Subject:/
+$_ =~ /^Subject:/
+tr/a-z/A-Z/
+$_ =~ tr/a-z/A-Z/
+chomp
+chomp($_)
+Here are the places where Perl will assume $_ even if you don't use it:
+ Various unary functions, including functions like ord() and int(), as well as 
the all file tests (-f, -d) except for -t, which defaults to STDIN.
+ Various list functions like print() and unlink().
+ The pattern matching operations m//, s///, and tr/// when used without an =~ 
operator.
+ The default iterator variable in a foreach loop if no other variable is 
supplied.
+ The implicit iterator variable in the grep() and map() functions.
+ The default place to put an input record when a FH operation's result is 
tested by itself as the sole criterion of a while test. Outside a while test, 
this will not happen.
+(Mnemonic: underline is understood in certain operations.)
+$digits
+Contains the subpattern from the corresponding set of capturing parentheses 
from the last pattern match, not counting patterns matched in nested blocks 
that have been exited already. (Mnemonic: like \digits.) These variables are 
all read-only and dynamically scoped to the current BLOCK.
+$MATCH
+$
+The string matched by the last successful pattern match (not counting any 
matches hidden within a BLOCK or eval() enclosed by the current BLOCK). 
(Mnemonic: like  in some editors.) This variable is read-only and dynamically 
scoped to the current BLOCK.
+The use of this variable anywhere in a program imposes a considerable 
performance penalty on all regular expression matches. See BUGS.
+$PREMATCH
+$`
+The string preceding whatever was matched by the last successful pattern match 
(not counting any matches hidden within a BLOCK or eval enclosed by the current 
BLOCK). (Mnemonic: ` often precedes a quoted string.) This variable is 
read-only.
+The use of this variable anywhere in a program imposes a considerable 
performance penalty on all regular expression matches. See BUGS.
+$POSTMATCH
+$'
+The string following whatever was matched by the last successful pattern match 
(not counting any matches hidden within a BLOCK or eval() enclosed by the 
current BLOCK). (Mnemonic: ' often follows a quoted string.) Example:
+$_ = 'abcdefghi';
+/def/;
+print $`:$:$'\n; # prints abc:def:ghi
+This variable is read-only and dynamically scoped to the current BLOCK.
+The use of this variable anywhere in a program imposes a considerable 
performance penalty on all regular expression matches. See BUGS.
+$LAST_PAREN_MATCH
+$+
+The last bracket matched by the last search pattern. This is useful if you 
don't know which one of a set of alternative patterns matched. For example:
+

Change 30710: Re-sorting the MANIFEST after the mess made of it with the

2007-03-22 Thread Steve Peters
Change 30710 by [EMAIL PROTECTED] on 2007/03/23 02:17:50

Re-sorting the MANIFEST after the mess made of it with the
Pod-Simple renamings

Affected files ...

... //depot/perl/MANIFEST#1535 edit

Differences ...

 //depot/perl/MANIFEST#1535 (text) 
Index: perl/MANIFEST
--- perl/MANIFEST#1534~30706~   2007-03-22 18:43:11.0 -0700
+++ perl/MANIFEST   2007-03-22 19:17:50.0 -0700
@@ -882,8 +882,8 @@
 ext/Math/BigInt/FastCalc/Makefile.PL   Math::BigInt::FastCalc extension
 ext/Math/BigInt/FastCalc/t/bigintfc.t  Math::BigInt::FastCalc extension
 ext/Math/BigInt/FastCalc/t/bootstrap.t Math::BigInt::FastCalc extension
-ext/Math/BigInt/FastCalc/t/mbi_rand.t  Math::BigInt::FastCalc extension
 ext/Math/BigInt/FastCalc/t/leak.t  test for memory leaks in 
Math::BigInt::FastCalc
+ext/Math/BigInt/FastCalc/t/mbi_rand.t  Math::BigInt::FastCalc extension
 ext/MIME/Base64/Base64.pm  MIME::Base64 extension
 ext/MIME/Base64/Base64.xs  MIME::Base64 extension
 ext/MIME/Base64/ChangesMIME::Base64 extension
@@ -1213,16 +1213,6 @@
 ext/Unicode/Normalize/t/test.t Unicode::Normalize
 ext/Unicode/Normalize/t/tie.t  Unicode::Normalize
 ext/util/make_ext  Used by Makefile to execute extension Makefiles
-ext/Win32/Makefile.PL  Win32 extension makefile writer
-ext/Win32/t/ExpandEnvironmentStrings.t See if Win32 extension works
-ext/Win32/t/GetFileVersion.t   See if Win32 extension works
-ext/Win32/t/GetFolderPath.tSee if Win32 extension works
-ext/Win32/t/GetFullPathName.t  See if Win32 extension works
-ext/Win32/t/GetLongPathName.t  See if Win32 extension works
-ext/Win32/t/GetOSVersion.t See if Win32 extension works
-ext/Win32/t/GuidGen.t  See if Win32 extension works
-ext/Win32/Win32.pm Win32 extension Perl module
-ext/Win32/Win32.xs Win32 extension external subroutines
 ext/Win32API/File/buffers.hWin32API::File extension
 ext/Win32API/File/cFile.h  Win32API::File extension
 ext/Win32API/File/cFile.pc Win32API::File extension
@@ -1240,6 +1230,16 @@
 ext/Win32CORE/t/win32core.tWin32CORE extension
 ext/Win32CORE/Win32CORE.c  Win32CORE extension
 ext/Win32CORE/Win32CORE.pm Win32CORE extension (stubs for Win32 CORE subs)
+ext/Win32/Makefile.PL  Win32 extension makefile writer
+ext/Win32/t/ExpandEnvironmentStrings.t See if Win32 extension works
+ext/Win32/t/GetFileVersion.t   See if Win32 extension works
+ext/Win32/t/GetFolderPath.tSee if Win32 extension works
+ext/Win32/t/GetFullPathName.t  See if Win32 extension works
+ext/Win32/t/GetLongPathName.t  See if Win32 extension works
+ext/Win32/t/GetOSVersion.t See if Win32 extension works
+ext/Win32/t/GuidGen.t  See if Win32 extension works
+ext/Win32/Win32.pm Win32 extension Perl module
+ext/Win32/Win32.xs Win32 extension external subroutines
 ext/XS/APItest/APItest.pm  XS::APItest extension
 ext/XS/APItest/APItest.xs  XS::APItest extension
 ext/XS/APItest/core.c  Test API functions when PERL_CORE is defined
@@ -1257,8 +1257,8 @@
 ext/XS/APItest/t/printf.t  XS::APItest extension
 ext/XS/APItest/t/push.tXS::APItest extension
 ext/XS/APItest/t/svsetsv.t Test behaviour of sv_setsv with/without 
PERL_CORE
-ext/XS/APItest/t/xs_special_subs.t Test that XS BEGIN/CHECK/INIT/END work
 ext/XS/APItest/t/xs_special_subs_require.t for require too
+ext/XS/APItest/t/xs_special_subs.t Test that XS BEGIN/CHECK/INIT/END work
 ext/XS/Typemap/Makefile.PL XS::Typemap extension
 ext/XS/Typemap/README  XS::Typemap extension
 ext/XS/Typemap/stdio.c XS::Typemap extension
@@ -2320,22 +2320,6 @@
 lib/Pod/Simple/t/cbacks.t  Pod::Simple test file
 lib/Pod/Simple/t/chunking.tPod::Simple test file
 lib/Pod/Simple/t/closeys.t Pod::Simple test file
-lib/Pod/Simple/t/corpus/cp1256.txt Pod::Simple test file
-lib/Pod/Simple/t/corpus/cp1256.xml Pod::Simple test file
-lib/Pod/Simple/t/corpus/iso6.txt   Pod::Simple test file
-lib/Pod/Simple/t/corpus/iso6.xml   Pod::Simple test file
-lib/Pod/Simple/t/corpus/fet_cont.txt   Pod::Simple test file
-lib/Pod/Simple/t/corpus/fet_cont.xml   Pod::Simple test file
-lib/Pod/Simple/t/corpus/fet_dup.txtPod::Simple test file
-lib/Pod/Simple/t/corpus/fet_dup.xmlPod::Simple test file
-lib/Pod/Simple/t/corpus/koi8r.txt  Pod::Simple test file
-lib/Pod/Simple/t/corpus/koi8r.xml  Pod::Simple test file
-lib/Pod/Simple/t/corpus/lat1frim.txt   Pod::Simple test file
-lib/Pod/Simple/t/corpus/lat1frim.xml   Pod::Simple test file
-lib/Pod/Simple/t/corpus/lat1fr.txt Pod::Simple test file
-lib/Pod/Simple/t/corpus/lat1fr.xml Pod::Simple test file
-lib/Pod/Simple/t/corpus/8859_7.pod Pod::Simple test file
-lib/Pod/Simple/t/corpus/8859_7.xml Pod::Simple test file
 lib/Pod/Simple/t/corpus/2202jp.txt.packed  Pod::Simple test file
 lib/Pod/Simple/t/corpus/2202jp.xml Pod::Simple 

Change 30711: Upgrade to Test-Simple-0.70

2007-03-22 Thread Steve Peters
Change 30711 by [EMAIL PROTECTED] on 2007/03/23 03:36:47

Upgrade to Test-Simple-0.70

Affected files ...

... //depot/perl/lib/Test/Builder.pm#23 edit
... //depot/perl/lib/Test/More.pm#34 edit
... //depot/perl/lib/Test/Simple.pm#28 edit
... //depot/perl/lib/Test/Simple/Changes#23 edit
... //depot/perl/lib/Test/Simple/t/is_fh.t#5 edit

Differences ...

 //depot/perl/lib/Test/Builder.pm#23 (text) 
Index: perl/lib/Test/Builder.pm
--- perl/lib/Test/Builder.pm#22~30578~  2007-03-14 06:17:42.0 -0700
+++ perl/lib/Test/Builder.pm2007-03-22 20:36:47.0 -0700
@@ -8,7 +8,7 @@
 
 use strict;
 use vars qw($VERSION);
-$VERSION = '0.68';
+$VERSION = '0.70';
 $VERSION = eval $VERSION;# make the alpha version come out as a number
 
 # Make Test::Builder thread-safe for ithreads.
@@ -1025,10 +1025,10 @@
 my $maybe_fh = shift;
 return 0 unless defined $maybe_fh;
 
-return 1 if ref \$maybe_fh eq 'GLOB'; # its a glob
+return 1 if ref $maybe_fh  eq 'GLOB'; # its a glob
+return 1 if ref \$maybe_fh eq 'GLOB'; # its a glob ref
 
-return eval { $maybe_fh-isa(GLOB) }   ||
-   eval { $maybe_fh-isa(IO::Handle) } ||
+return eval { $maybe_fh-isa(IO::Handle) } ||
# 5.5.4's tied() and can() doesn't like getting undef
eval { (tied($maybe_fh) || '')-can('TIEHANDLE') };
 }

 //depot/perl/lib/Test/More.pm#34 (text) 
Index: perl/lib/Test/More.pm
--- perl/lib/Test/More.pm#33~30578~ 2007-03-14 06:17:42.0 -0700
+++ perl/lib/Test/More.pm   2007-03-22 20:36:47.0 -0700
@@ -16,7 +16,7 @@
 
 
 use vars qw($VERSION @ISA @EXPORT %EXPORT_TAGS $TODO);
-$VERSION = '0.68';
+$VERSION = '0.70';
 $VERSION = eval $VERSION;# make the alpha version come out as a number
 
 use Test::Builder::Module;

 //depot/perl/lib/Test/Simple.pm#28 (text) 
Index: perl/lib/Test/Simple.pm
--- perl/lib/Test/Simple.pm#27~30578~   2007-03-14 06:17:42.0 -0700
+++ perl/lib/Test/Simple.pm 2007-03-22 20:36:47.0 -0700
@@ -4,7 +4,7 @@
 
 use strict 'vars';
 use vars qw($VERSION @ISA @EXPORT);
-$VERSION = '0.68';
+$VERSION = '0.70';
 $VERSION = eval $VERSION;# make the alpha version come out as a number
 
 use Test::Builder::Module;

 //depot/perl/lib/Test/Simple/Changes#23 (text) 
Index: perl/lib/Test/Simple/Changes
--- perl/lib/Test/Simple/Changes#22~30578~  2007-03-14 06:17:42.0 
-0700
+++ perl/lib/Test/Simple/Changes2007-03-22 20:36:47.0 -0700
@@ -1,3 +1,13 @@
+0.70  Thu Mar 15 15:53:05 PDT 2007
+Bug Fixes
+* The change to is_fh() in 0.68 broke the case where a reference to
+  a tied filehandle is used for perl 5.6 and back.  This made the tests
+  puke their guts out.
+
+0.69  Wed Mar 14 06:43:35 PDT 2007
+Test fixes
+- Minor filename compatibility fix to t/fail-more.t [rt.cpan.org 25428]
+
 0.68  Tue Mar 13 17:27:26 PDT 2007
 Bug fixes
 * If your code has a $SIG{__DIE__} handler in some cases functions like

 //depot/perl/lib/Test/Simple/t/is_fh.t#5 (text) 
Index: perl/lib/Test/Simple/t/is_fh.t
--- perl/lib/Test/Simple/t/is_fh.t#4~30578~ 2007-03-14 06:17:42.0 
-0700
+++ perl/lib/Test/Simple/t/is_fh.t  2007-03-22 20:36:47.0 -0700
@@ -11,7 +11,7 @@
 }
 
 use strict;
-use Test::More tests = 8;
+use Test::More tests = 10;
 use TieOut;
 
 ok( !Test::Builder-is_fh(foo), 'string is not a filehandle' );
@@ -27,3 +27,10 @@
 
 tie *OUT, 'TieOut';
 ok( Test::Builder-is_fh(*OUT) );
+ok( Test::Builder-is_fh(\*OUT) );
+
+SKIP: {
+skip *TIED_HANDLE{IO} doesn't work in this perl, 1
+unless defined *OUT{IO};
+ok( Test::Builder-is_fh(*OUT{IO}) );
+}
End of Patch.


Change 30712: Upgrade to CPAN-1.88_79

2007-03-22 Thread Steve Peters
Change 30712 by [EMAIL PROTECTED] on 2007/03/23 03:45:30

Upgrade to CPAN-1.88_79

Affected files ...

... //depot/perl/lib/CPAN.pm#113 edit

Differences ...

 //depot/perl/lib/CPAN.pm#113 (text) 
Index: perl/lib/CPAN.pm
--- perl/lib/CPAN.pm#112~30551~ 2007-03-12 08:12:39.0 -0700
+++ perl/lib/CPAN.pm2007-03-22 20:45:30.0 -0700
@@ -1,7 +1,7 @@
 # -*- Mode: cperl; coding: utf-8; cperl-indent-level: 4 -*-
 use strict;
 package CPAN;
-$CPAN::VERSION = '1.88_78';
+$CPAN::VERSION = '1.88_79';
 $CPAN::VERSION = eval $CPAN::VERSION;
 
 use CPAN::HandleConfig;
@@ -370,6 +370,19 @@
 # $CPAN::Frontend-mywarn('$yaml_module' not installed, falling back 
to 'YAML'\n);
 $yaml_module = YAML;
 }
+if ($yaml_module eq YAML
+
+$CPAN::META-has_inst($yaml_module)
+
+$YAML::VERSION  0.60
+
+!$Have_warned-{YAML}++
+   ) {
+$CPAN::Frontend-mywarn(Warning: YAML version '$YAML::VERSION' is too 
low, please upgrade!\n.
+I'll continue but problems are *very* likely 
to happen.\n
+   );
+$CPAN::Frontend-mysleep(5);
+}
 return $yaml_module;
 }
 
@@ -552,20 +565,65 @@
 sub new {
 my($class) = shift;
 my($deps) = shift;
-my @deps;
-my %seen;
-for my $dep (@$deps) {
-push @deps, $dep;
-last if $seen{$dep}++;
+my (@deps,%seen,$loop_starts_with);
+  DCHAIN: for my $dep (@$deps) {
+push @deps, {name = $dep, display_as = $dep};
+if ($seen{$dep}++){
+$loop_starts_with = $dep;
+last DCHAIN;
+}
+}
+my $in_loop = 0;
+for my $i (0..$#deps) {
+my $x = $deps[$i]{name};
+$in_loop ||= $x eq $loop_starts_with;
+my $xo = CPAN::Shell-expandany($x) or next;
+if ($xo-isa(CPAN::Module)) {
+my $have = $xo-inst_version || N/A;
+my($want,$d,$want_type);
+if ($i0 and $d = $deps[$i-1]{name}) {
+my $do = CPAN::Shell-expandany($d);
+$want = $do-{prereq_pm}{requires}{$x};
+if (defined $want) {
+$want_type = requires: ;
+} else {
+$want = $do-{prereq_pm}{build_requires}{$x};
+if (defined $want) {
+$want_type = build_requires: ;
+} else {
+$want_type = unknown status;
+$want = ???;
+}
+}
+} else {
+$want = $xo-cpan_version;
+$want_type = want: ;
+}
+$deps[$i]{have} = $have;
+$deps[$i]{want_type} = $want_type;
+$deps[$i]{want} = $want;
+$deps[$i]{display_as} = $x (have: $have; $want_type$want);
+} elsif ($xo-isa(CPAN::Distribution)) {
+$deps[$i]{display_as} = $xo-pretty_id;
+if ($in_loop) {
+$xo-{make} = CPAN::Distrostatus-new(NO cannot resolve 
circular dependency);
+} else {
+$xo-{make} = CPAN::Distrostatus-new(NO one dependency 
($loop_starts_with) is a circular dependency);
+}
+$xo-store_persistent_state; # otherwise I will not reach
+ # all involved parties for
+ # the next session
+}
 }
 bless { deps = [EMAIL PROTECTED] }, $class;
 }
 
 sub as_string {
 my($self) = shift;
-\nRecursive dependency detected:\n .
-join(\n = , @{$self-{deps}}) .
-.\nCannot continue.\n;
+my $ret = \nRecursive dependency detected:\n;
+$ret .= join(\n = , map {$_-{display_as}} @{$self-{deps}});
+$ret .= .\nCannot resolve.\n;
+$ret;
 }
 
 package CPAN::Exception::yaml_not_installed;
@@ -2968,8 +3026,22 @@
if (0) {
 } elsif (ref $obj) {
 if ($meth =~ /^($needs_recursion_protection)$/) {
-# silly for look or dump
-$obj-color_cmd_tmps(0,1);
+# it would be silly to check for recursion for look or dump
+# (we are in CPAN::Shell::rematein)
+CPAN-debug(Going to test against recursion) if $CPAN::DEBUG;
+eval {  $obj-color_cmd_tmps(0,1); };
+if ($@){
+if (ref $@
+and [EMAIL 
PROTECTED]isa(CPAN::Exception::RecursiveDependency)) {
+$CPAN::Frontend-mywarn($@);
+} else {
+if (0) {
+require Carp;
+Carp::confess(sprintf DEBUG: [EMAIL PROTECTED], 
$@, ref $@);
+}
+die;
+}
+}
 }
 CPAN::Queue-new(qmod = $obj-id, reqtype = c);
 push