From: Gurusamy Sarathy Date: Sat, 23 May 1998 18:02:21 +0000 (+0000) Subject: [win32] merge change#1011 from maintbranch X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=cca87523cf2ee6eb48a8a0b1a57f8bea2c4b1915;p=p5sagit%2Fp5-mst-13.2.git [win32] merge change#1011 from maintbranch p4raw-link: @1011 on //depot/maint-5.004/perl: b1b8a6f107d7c2d590be5dde4bedaf8d36872c82 p4raw-id: //depot/win32/perl@1027 --- diff --git a/perl.c b/perl.c index fe00dcf..146367d 100644 --- a/perl.c +++ b/perl.c @@ -2173,7 +2173,6 @@ static I32 read_e_script(int idx, SV *buf_sv, int maxlen) { char *p, *nl; - FILTER_READ(idx+1, buf_sv, maxlen); p = SvPVX(e_script); nl = strchr(p, '\n'); nl = (nl) ? nl+1 : SvEND(e_script); diff --git a/pod/perldiag.pod b/pod/perldiag.pod index d515517..93d0f3d 100644 --- a/pod/perldiag.pod +++ b/pod/perldiag.pod @@ -878,34 +878,17 @@ weren't. subscript. But to the left of the brackets was an expression that didn't look like an array reference, or anything else subscriptable. -=item Can't write to temp file for B<-e>: %s - -(F) The write routine failed for some reason while trying to process -a B<-e> switch. Maybe your /tmp partition is full, or clobbered. - =item Can't x= to read-only value (F) You tried to repeat a constant value (often the undefined value) with an assignment operator, which implies modifying the value itself. Perhaps you need to copy the value to a temporary, and repeat that. -=item Cannot create temporary file "%s" - -(F) A temporary file could not created for some reason while trying to -process a B<-e> switch. Maybe your temporary file partition is full, -or over-protected, or clobbered. - =item Cannot find an opnumber for "%s" (F) A string of a form C was given to prototype(), but there is no builtin with the name C. -=item Cannot generate temporary filename - -(F) While trying to process a B<-e> switch, a filename for a temporary -file could not be generated. Maybe your temporary file partition is -full, or over-protected, or clobbered. - =item Cannot resolve method `%s' overloading `%s' in package `%s' (F|P) Error resolving overloading specified by a method name (as diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod index 28a3ba1..16292f6 100644 --- a/pod/perlfunc.pod +++ b/pod/perlfunc.pod @@ -4047,6 +4047,22 @@ Vectors created with vec() can also be manipulated with the logical operators |, &, and ^, which will assume a bit vector operation is desired when both operands are strings. +The following code will build up an ASCII string saying 'PerlPerlPerl'. +The comments show the string after each step. Note that this code works +in the same way on big-endian or little-endian machines. + + my $foo = ''; + vec($foo, 0, 32) = 0x5065726C; # 'Perl' + vec($foo, 2, 16) = 0x5065; # 'PerlPe' + vec($foo, 3, 16) = 0x726C; # 'PerlPerl' + vec($foo, 8, 8) = 0x50; # 'PerlPerlP' + vec($foo, 9, 8) = 0x65; # 'PerlPerlPe' + vec($foo, 20, 4) = 2; # 'PerlPerlPe' . "\x02" + vec($foo, 21, 4) = 7; # 'PerlPerlPer' # 'r' is "\x72" + vec($foo, 45, 2) = 3; # 'PerlPerlPer' . "\x0c" + vec($foo, 93, 1) = 1; # 'PerlPerlPer' . "\x2c" + vec($foo, 94, 1) = 1; # 'PerlPerlPerl' # 'l' is "\x6c" + To transform a bit vector into a string or array of 0's and 1's, use these: $bits = unpack("b*", $vector); diff --git a/pp_ctl.c b/pp_ctl.c index 61e940f..de960a2 100644 --- a/pp_ctl.c +++ b/pp_ctl.c @@ -2465,7 +2465,7 @@ PP(pp_require) SvREFCNT_dec(namesv); if (!tryrsfp) { if (op->op_type == OP_REQUIRE) { - SV *msg = sv_2mortal(newSVpvf("Can't locate '%s' in @INC", name)); + SV *msg = sv_2mortal(newSVpvf("Can't locate %s in @INC", name)); SV *dirmsgsv = NEWSV(0, 0); AV *ar = GvAVn(incgv); I32 i; diff --git a/utils/perlbug.PL b/utils/perlbug.PL index 68ff290..4685e42 100644 --- a/utils/perlbug.PL +++ b/utils/perlbug.PL @@ -84,7 +84,7 @@ BEGIN { $::HaveUtil = ($@ eq ""); }; -my $Version = "1.22"; +my $Version = "1.23"; # Changed in 1.06 to skip Mail::Send and Mail::Util if not available. # Changed in 1.07 to see more sendmail execs, and added pipe output. @@ -111,6 +111,7 @@ my $Version = "1.22"; # Changed in 1.20 Added patchlevel.h reading and version/config checks # Changed in 1.21 Added '-nok' for reporting build failure DFD 98-05-05 # Changed in 1.22 Heavy reformatting & minor bugfixes HVDS 98-05-10 +# Changed in 1.23 Restore -ok(ay): say 'success'; don't prompt # TODO: - Allow the user to re-name the file on mail failure, and # make sure failure (transmission-wise) of Mail::Send is @@ -137,7 +138,7 @@ EOF if (!-t STDOUT) { Dump(*STDOUT); exit; } Query(); -Edit() unless $usefile; +Edit() unless $usefile || ($ok and not $::opt_n); NowWhat(); Send(); @@ -435,7 +436,7 @@ EOF # Generate report open(REP,">$filename"); - my $reptype = $ok ? "build failure" : "bug"; + my $reptype = !$ok ? "bug" : $::opt_n ? "build failure" : "success"; print REP <