platform/upstream/perl.git
10 years agoperldelta - Two more module upgrades
Steve Hay [Tue, 10 Sep 2013 08:11:07 +0000 (09:11 +0100)]
perldelta - Two more module upgrades

10 years agoCorrect typos reported by Terry Speirs++.
James E Keenan [Mon, 9 Sep 2013 23:05:05 +0000 (01:05 +0200)]
Correct typos reported by Terry Speirs++.

For: RT #119673

10 years agoUpdate EXCLUDED for CPAN-Meta-Requirements following 7cb95fb75d
Steve Hay [Mon, 9 Sep 2013 19:52:08 +0000 (20:52 +0100)]
Update EXCLUDED for CPAN-Meta-Requirements following 7cb95fb75d

10 years agort119311.t: typo
Father Chrysostomos [Mon, 9 Sep 2013 15:21:13 +0000 (08:21 -0700)]
rt119311.t: typo

10 years agoMake &xsub and goto &xsub work with tied @_
Father Chrysostomos [Mon, 9 Sep 2013 08:59:33 +0000 (01:59 -0700)]
Make &xsub and goto &xsub work with tied @_

This is the only place where tied @_ does not work, and there appears
to be no reason why it shouldn’t, apart from the fact that it hasn’t
been implemented.

Commit 67955e0c was what made &xsub work to begin with.  93965878572
introduced tied arrays and added the comment to pp_entersub saying
that @_ is not tiable.

goto &xsub has worked since perl 5.000, but 93965878572 did not make
it work with tied arrays.

10 years agoDumper.xs: Update comment
Father Chrysostomos [Mon, 9 Sep 2013 08:47:42 +0000 (01:47 -0700)]
Dumper.xs: Update comment

10 years agoperl5200delta: 2 modules fixed; one misspelt
Father Chrysostomos [Mon, 9 Sep 2013 08:16:27 +0000 (01:16 -0700)]
perl5200delta: 2 modules fixed; one misspelt

10 years agoExtUtils::Command has been synchronised to CPAN
Florian Ragwitz [Mon, 9 Sep 2013 13:18:19 +0000 (09:18 -0400)]
ExtUtils::Command has been synchronised to CPAN

10 years agoUpgrade Parse::CPAN::Meta from version 1.4405 to 1.4407
Steve Hay [Mon, 9 Sep 2013 08:09:45 +0000 (09:09 +0100)]
Upgrade Parse::CPAN::Meta from version 1.4405 to 1.4407

10 years agoUpgrade ExtUtils::CBuilder from version 0.280210 to 0.280212
Steve Hay [Mon, 9 Sep 2013 07:57:16 +0000 (08:57 +0100)]
Upgrade ExtUtils::CBuilder from version 0.280210 to 0.280212

10 years agoUpgrade CPAN::Meta from version 2.132140 to 2.132510
Steve Hay [Mon, 9 Sep 2013 07:46:18 +0000 (08:46 +0100)]
Upgrade CPAN::Meta from version 2.132140 to 2.132510

10 years agoSort the list of IGNORABLES in Porting/Maintainers.pl
Steve Hay [Mon, 9 Sep 2013 07:36:14 +0000 (08:36 +0100)]
Sort the list of IGNORABLES in Porting/Maintainers.pl

10 years agoAdd mods from #119433 to perl5200delta
Father Chrysostomos [Mon, 9 Sep 2013 08:08:57 +0000 (01:08 -0700)]
Add mods from #119433 to perl5200delta

10 years agoperlio.c: misuse of SvPV_nolen_const
Father Chrysostomos [Mon, 9 Sep 2013 07:53:43 +0000 (00:53 -0700)]
perlio.c: misuse of SvPV_nolen_const

SvPV_nolen_const takes only one argument and does not return
a length.

10 years agoFix buffer overflow with overlong identifiers
Father Chrysostomos [Mon, 9 Sep 2013 07:35:38 +0000 (00:35 -0700)]
Fix buffer overflow with overlong identifiers

This was introduced by commit 32833930e32dc in 5.17.10.

$  ./perl -Ilib -e Foooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo
Identifier too long at -e line 1.
Segmentation fault: 11

(That was an amusing use of macro parentheses for the while condition,
at least while it lasted.)

10 years agoFix -DP output
Father Chrysostomos [Mon, 9 Sep 2013 07:15:58 +0000 (00:15 -0700)]
Fix -DP output

broken by b66f3475d343.

$ ./perl -Ilib -DP
Screamer: entering, ptr=140185618803200, cnt=0
Screamer: entering: PerlIO * thinks ptr=140185618803200, cnt=%z, base=0
Screamer: going to getc, ptr=140185618803200, cnt=%z
^C

The format is %zd, not %z.

10 years agoDon’t let reblessing point SvSTASH to a half-freed stash
Father Chrysostomos [Mon, 9 Sep 2013 06:05:40 +0000 (23:05 -0700)]
Don’t let reblessing point SvSTASH to a half-freed stash

We should set SvSTASH before calling SvREFCNT_dec on its old value,
otherwise we could free the old stash and trigger a DESTROY that sees
the object blessed into the half-freed stash.

Currently, a second call to bless inside DESTROY can trigger ‘Attempt
to free unreferenced scalar’, because it calls SvREFCNT_dec a second
time on the stash that already has a reference count of 0.

10 years agoFix assertion failure with -DT -e\"
Father Chrysostomos [Mon, 9 Sep 2013 01:51:56 +0000 (18:51 -0700)]
Fix assertion failure with -DT -e\"

$ ./perl -DT -e\"
Assertion failed: (s), function S_printbuf, file toke.c, line 479.
Abort trap: 6

10 years ago[perl #117265] fix various problems with safesyscalls
Tony Cook [Mon, 9 Sep 2013 05:36:26 +0000 (15:36 +1000)]
[perl #117265] fix various problems with safesyscalls

- handling "" overloading correctly
- avoid an extraneous warning from glob()

10 years ago[perl #117265] move the "glob failed" warning to the point of failure
Tony Cook [Thu, 5 Sep 2013 04:14:00 +0000 (14:14 +1000)]
[perl #117265] move the "glob failed" warning to the point of failure

This avoids an extraneous warning when globbing fails for other reasons.

10 years ago[perl #117265] do most glob \0 checks in the same place
Tony Cook [Tue, 3 Sep 2013 23:55:53 +0000 (09:55 +1000)]
[perl #117265] do most glob \0 checks in the same place

and before we do much processing

10 years ago[perl #117265] correctly handle overloaded strings
Tony Cook [Tue, 3 Sep 2013 00:17:35 +0000 (10:17 +1000)]
[perl #117265] correctly handle overloaded strings

10 years ago[perl #117265] TODO tests for overloading issues
Tony Cook [Mon, 2 Sep 2013 23:05:09 +0000 (09:05 +1000)]
[perl #117265] TODO tests for overloading issues

10 years agoFix line numbers with #! -d:foo and PERL5DB=$'\n'
Father Chrysostomos [Sun, 8 Sep 2013 20:49:22 +0000 (13:49 -0700)]
Fix line numbers with #! -d:foo and PERL5DB=$'\n'

Commit 2179133 inadvertently stopped the PERL5DB env var from being
truncated just before the first line break.  (I’m considering that
a bug fix.)

The result is that #!perl -d:foo will throw the line numbers off by
one, as will line breaks in PERL5DB:

$ PERL5DB='sub DB::DB{}'$'\n\n\n''' ./perl -dle 'warn "ok"'
ok at -e line 4.

#!perl -d:foo has thrown off line numbers since f0e67a1d291 in 5.12.

This commit fixes both, by storing the line number of #! -d or the
number 0 for -d on the command line in the new PL_parser->preambling
member, which now overrides any number in PL_curcop.

10 years agoTest line breaks in PERL5DB
Father Chrysostomos [Tue, 27 Aug 2013 20:20:39 +0000 (13:20 -0700)]
Test line breaks in PERL5DB

$ PERL5DB='sub DB::DB{} die' perl5.18.1 -dle 'print "ok"'
Died.
$ PERL5DB='sub DB::DB{}
die' perl5.18.1 -dle 'print "ok"'
ok

So everything after the line break is ignored.

In bleadperl:

$ PERL5DB='sub DB::DB{} die' ./perl -dle 'print "ok"'
Died.
$ PERL5DB='sub DB::DB{}
die' ./perl -dle 'print "ok"'
Died at -e line 1.

Now the whole environment variable is used.  This was probably changed
by commit 2179133.

Let’s call it a bug fix and test it.

(The ‘at -e line 1’ is not right, but the next commit will fix it.)

10 years agoop.c:newSTATEOP: remove unnecessary null check
Father Chrysostomos [Wed, 28 Aug 2013 03:38:03 +0000 (20:38 -0700)]
op.c:newSTATEOP: remove unnecessary null check

If PL_parser is null, then the else block will crash on
PL_parser->copline.

10 years agoExtUtils::Manifest has been synchronised to CPAN
Florian Ragwitz [Sun, 8 Sep 2013 15:36:08 +0000 (11:36 -0400)]
ExtUtils::Manifest has been synchronised to CPAN

10 years agoRevert "Let av_push accept NULL values"
Father Chrysostomos [Sun, 8 Sep 2013 01:42:07 +0000 (18:42 -0700)]
Revert "Let av_push accept NULL values"

This reverts commit 7b6e8075e45ebc684565efbe3ce7b70435f20c79.

It turns out to be problematic, because it causes NULLs on the stack,
which XSUBs may trip on.

My main reason for it was actually to try to resolve some CPAN
failures, but it turns out that other fixes have removed the
need for that.

10 years agoMove herelines out of the lex_shared struct
Father Chrysostomos [Sun, 8 Sep 2013 01:34:24 +0000 (18:34 -0700)]
Move herelines out of the lex_shared struct

Previously, the line number was localised in lexing scopes.  herelines
had to be in the lex_shared struct so that inner lexing scopes
could peek into values belonging to outer lexing scopes and set the
herelines value belonging to the same scope that a here-doc body was
extracted from.  (herelines records how much extra to increase the
line number at the next line ending, to jump over a here-doc.)

In commit ffdb8b167e, I changed things so that lexing scopes no longer
localised the line number, except for here-docs, and the line number
was incremented within the inner lexing scope, instead of during the
initial scan for the terminator.  That meant the herelines value had
to be copied into the inner lexing scope.

For nested here-docs, the inner here-doc’s body is always inside the
outer here-doc, so no peeking into outer scopes is necessary.

Hence, there is no longer any reason for herelines to be inside the
lex_shared struct.  We can put it directly inside the parser struct.
Here-docs will localise it.  Other quote-like constructs will not (and
can avoid the copy.)

10 years agoRespect #line directives in here-docs
Father Chrysostomos [Sun, 8 Sep 2013 00:43:26 +0000 (17:43 -0700)]
Respect #line directives in here-docs

#line directives in here-docs used to be ignored after the heredoc:

<<END
${
#line 27
print __LINE__,"\n" # prints 27
}
END
; print __LINE__, "\n"; # prints 7

This commit changes that by recording in PL_multi_end the end of
the here-doc (more precisely, the last line of the body, before the
terminator) during the initial parse to find the terminator.  When
the body is parsed for double-quotish stuff, at the very end (in
sublex_done) the last line number is compared with the one recorded.
Any differences are applied to the current ‘herelines’ value, which
records how many line numbers need to be skipped when the line ending
after the here-doc marked (<<END) is reached.

It conflicts with a line number workaround in op.c, which hasn’t done
anything since I accidentally disabled it in 5.18.

Added in 0244c3a40, this code set the current line number to the end
of the here-doc when creating the substitution op for s//<<foo/e.
Before that, since the line number was localised to the lexing scope,
the new line number set by the here-doc would be undone when the s///
finished, throwing off all subsequent line numbers.

Commit 83944c0156 solved the problem of the line number for code after
the here-doc marker having the wrong line number (because the here-doc
parser would increase the line number by the number of lines in the
here-doc body straightaway).  It introduced the ‘herelines’ value,
recording how many lines the here-doc body contained, but without
updating the line number yet, so that code after the <<marker would
have the right line, but the next \n would increment the line number
by herelines+1.  That accidentally stopped PL_multi_end from having
the right value, disabling the line number code in op.c.  But the
other changes rendered that code unnecessary.

10 years agoregcomp.c:current_re_engine: Avoid %^H lookup when possible
Father Chrysostomos [Sat, 7 Sep 2013 20:34:24 +0000 (13:34 -0700)]
regcomp.c:current_re_engine: Avoid %^H lookup when possible

Modification of %^H sets a flag in PL_hints, so we can check
that flag to avoid the slight overhead of has lookup if %^H
has not been used.

10 years agoFix line numbers in <<foo,<<bar
Father Chrysostomos [Sat, 7 Sep 2013 07:27:28 +0000 (00:27 -0700)]
Fix line numbers in <<foo,<<bar

This used to print 9:

<<foo, <<bar
a
b
c
d
e
f
g
foo
${warn __LINE__ }
bar

even though the __LINE__ marker is on line 10.  In perl 5.18, I broke
it further, making it print 2.

This commit makes it print 10.  We just need to make sure
PL_multi_start is set correctly in scan_heredoc for a second here-doc
marker on the same line.

10 years agotoke.c: In sublex_push use multi_close to detect here-doc
Father Chrysostomos [Sat, 7 Sep 2013 06:45:36 +0000 (23:45 -0700)]
toke.c: In sublex_push use multi_close to detect here-doc

It is a lot simpler this way.  scan_heredoc already sets PL_multi_close
to '<' (the only code that does it).  That value does not appear to
be used anywhere.  Now it is.

Furthermore, this removes assumptions that the next commit will
likely violate.

10 years agoperldelta - More recent module upgrades
Steve Hay [Sun, 8 Sep 2013 00:40:56 +0000 (01:40 +0100)]
perldelta - More recent module upgrades

10 years agoData-Dumper/Dumper.pm: An EBCDIC fix
Karl Williamson [Fri, 5 Apr 2013 18:21:21 +0000 (12:21 -0600)]
Data-Dumper/Dumper.pm: An EBCDIC fix

Change the range 0-7F to the portable equivalent [:ascii:]

10 years agoTerm::ReadLine has been synchronised to CPAN
Florian Ragwitz [Sat, 7 Sep 2013 13:54:29 +0000 (09:54 -0400)]
Term::ReadLine has been synchronised to CPAN

10 years agoBump $Term::ReadLine::VERSION
Florian Ragwitz [Sat, 7 Sep 2013 14:13:25 +0000 (10:13 -0400)]
Bump $Term::ReadLine::VERSION

10 years agoAdd Tokuhiro Matsuno to AUTHORS
Florian Ragwitz [Sat, 7 Sep 2013 14:11:17 +0000 (10:11 -0400)]
Add Tokuhiro Matsuno to AUTHORS

10 years agoadded Term::ReadLine::EditLine support
Tokuhiro Matsuno [Sat, 26 Jan 2013 13:01:18 +0000 (22:01 +0900)]
added Term::ReadLine::EditLine support

10 years agoTerm::ReadLine has been synchronised to CPAN
Florian Ragwitz [Sat, 7 Sep 2013 13:54:29 +0000 (09:54 -0400)]
Term::ReadLine has been synchronised to CPAN

10 years agoFix processing of PERL_ENV_TABLES.
Craig A. Berry [Sat, 7 Sep 2013 11:55:25 +0000 (06:55 -0500)]
Fix processing of PERL_ENV_TABLES.

In a35dcc95dd24524931e I "improved" string safety in vms/vms.c by
converting to my_strlcpy and my_strlcat, but mangled the length
argument to my_strlcat when adding the name of the logical name
table specified in PERL_ENV_TABLES. This caused the command string
to be truncated, so a command that, for example, should have been:

    $ Show Logical * /Table=LNM$JOB
    ...

actually became:

    $ Show Logical * /Table=
    %DCL-W-VALREQ, missing qualifier or keyword value - supply all required values

Plus it turns out the strings holding the names of the tables were
being stored in dynamic string descriptors and were not
NUL-terminated, but the strl* functions require NUL-terminated
arguments.  So change those to static string descriptors and
allocate the exact amount of storage needed including room for a
NUL.

This was a regression in 5.16.0, first reported a couple of days
ago by Mark Daniel on comp.os.vms:

Date: Fri, 06 Sep 2013 12:56:01 +0930
From: Mark Daniel <mark.daniel [AT] wasd.vsm.com.au>
Newsgroups: comp.os.vms
Message-ID: <52294b4a$0$2875$c3e8da3$76491128@news.astraweb.com>

TODO: Figure out how and where to test this.

10 years agoFix PerlIO_get_cnt and friends
Leon Timmermans [Wed, 28 Aug 2013 13:06:29 +0000 (15:06 +0200)]
Fix PerlIO_get_cnt and friends

These functions worked with ints instead of SSize_t,

10 years agoFix segfault in filehandle duplication
Leon Timmermans [Sat, 7 Sep 2013 06:58:18 +0000 (08:58 +0200)]
Fix segfault in filehandle duplication

Previously PerlIOBase_dup didn't check if pushing the new layer succeeded
before (optionally) setting the utf8 flag. This could cause
segfaults-by-nullpointer.

10 years agoLet av_push accept NULL values
Father Chrysostomos [Sat, 7 Sep 2013 06:21:56 +0000 (23:21 -0700)]
Let av_push accept NULL values

Now that NULL is used for a nonexistent element, it is easy for XS
code to pass it to av_push().  av_store already accepts NULL, and
av_push already works with it on non-debugging builds, so there is
really no need for this restriction.

10 years agoStop Devel'Peek'Dump with no args from crashing
Father Chrysostomos [Sat, 7 Sep 2013 01:07:50 +0000 (18:07 -0700)]
Stop Devel'Peek'Dump with no args from crashing

I accidentally broke this in commit xxxxxxxx (5.19.3).  The crash hap-
pened at compile time.

10 years agoregcomp.c:S_concat_pat: Allow 64-bit array offsets
Father Chrysostomos [Fri, 6 Sep 2013 23:06:07 +0000 (16:06 -0700)]
regcomp.c:S_concat_pat: Allow 64-bit array offsets

10 years agoMake /@array/ handle nonexistent array elements
Father Chrysostomos [Fri, 6 Sep 2013 23:04:40 +0000 (16:04 -0700)]
Make /@array/ handle nonexistent array elements

Commit ce0d59f changed AVs to use NULLs for nonexistent elements.

S_concat_pat in regcomp.c needs to account for that, to
avoid crashing.

10 years agoAllow 64-bit array and stack offsets in entersub & goto
Father Chrysostomos [Fri, 6 Sep 2013 19:35:56 +0000 (12:35 -0700)]
Allow 64-bit array and stack offsets in entersub & goto

I don’t have enough memory to test this, but it needs to be done even-
tually anyway.

10 years agoStop &xsub and goto &xsub from crashing on undef *_
Father Chrysostomos [Fri, 6 Sep 2013 15:30:41 +0000 (08:30 -0700)]
Stop &xsub and goto &xsub from crashing on undef *_

$ perl -e 'undef *_; &Internals::V'
Segmentation fault: 11
$ perl -e 'sub { undef *_; goto &Internals::V }->()'
$ perl5.18.1 -e 'sub { undef *_; goto &Internals::V }->()'
Segmentation fault: 11

The goto case is actually a regression from 5.16 (049bd5ffd62), as
goto used to ignore changes to *_.  (Fixing one bug uncovers another.)

We shouldn’t assume that GvAV(PL_defgv) (*_{ARRAY}) gives us anything.

While we’re at it, since we have to add extra checks anyway, use them
to speed up empty @_ in goto (by checking items, rather than arg).

10 years agoUpdated ExtUtils::CBuilder to 0.280210
Leon Timmermans [Sat, 7 Sep 2013 04:31:53 +0000 (06:31 +0200)]
Updated ExtUtils::CBuilder to 0.280210

10 years agoperldelta - Note recent module upgrades
Steve Hay [Fri, 6 Sep 2013 22:36:17 +0000 (23:36 +0100)]
perldelta - Note recent module upgrades

10 years agoPATCH: [perl #119601] Bleadperl breaks ETHER/Devel-Declare
Karl Williamson [Fri, 6 Sep 2013 20:02:25 +0000 (14:02 -0600)]
PATCH: [perl #119601] Bleadperl breaks ETHER/Devel-Declare

I will not otherwise mention that stealing .c code from the core is a
dangerous practice.

This is actually a bug in the module, which had been masked until now.
The first two parameters to utf8_to_uvchr_buf() are both U8*.  But  both
's' and PL_bufend are char*.  The 's' has a cast to U8* in the failing
line, but not PL_bufend.

Interestingly, the line in the official toke.c (introduced in 4b88fb76)
has always been right, so the stealer didn't copy it correctly.

What de69f3af3 did was turn this former function call into a macro that
manipulates the parameters and calls another function, thereby removing
a layer of function call overhead.  The manipulation involves
subtracting 's' from PL_bufend, and this fails to compile due to the
missing cast on the latter parameter.

The problem goes away if the macro casts both parameters to U8*, and
that is what this commit does.

10 years agoRemove Configure hints for the old AT&T 3b1.
Andy Dougherty [Fri, 6 Sep 2013 12:44:52 +0000 (08:44 -0400)]
Remove Configure hints for the old AT&T 3b1.

I am unaware of any successful builds since the 5.005 era.

10 years agopp_goto: document the different branches
David Mitchell [Fri, 6 Sep 2013 14:54:10 +0000 (15:54 +0100)]
pp_goto: document the different branches

Te various different forms of goto (and dump) take different branches
through this big function. Document which branches handle which variants.
Also document the use of OPf_SPECIAL in OP_DUMP.

10 years agoUpdate ExtUtils-MakeMaker to CPAN version 6.76
Chris 'BinGOs' Williams [Fri, 6 Sep 2013 12:59:45 +0000 (13:59 +0100)]
Update ExtUtils-MakeMaker to CPAN version 6.76

  [DELTA]

6.76 Fri Sep  6 13:32:42 BST 2013

    No changes from 6.75_04

6.75_04 Thu Sep  5 12:07:59 BST 2013
    Bug fixes:
    * Sanitise make on MSWin32 when reporting Makefile type

6.75_03 Tue Sep  3 00:24:23 BST 2013
    New features:
    * Added RECURSIVE_TEST_FILES attribute to 'test'
    * Report the type of Makefile being generated

    Bug fixes:
    * RT#17041 more sortification of hashes to Makefile

6.75_02 Sun Sep  1 21:50:48 BST 2013
    Bug fixes:
    * RT#49043 binmode STDIN breaks prompt() on MSWin32
    * RT#14505 Handle -Wl,-rpath correctly
    * RT#17041 Sort manification and copying events for perceptive
      cleanliness

6.75_01 Thu Aug 29 15:06:27 BST 2013
    New features:
    * Added NO_PERLLOCAL option to allow suppression of writing
      installs to perllocal.pod
    * Added NO_PACKLIST option to allow suppression of writing
      packlist files for installations

    Bug Fixes:
    * RT#32894 deal with legitimate linker flags correctly
    * RT#88222 check that Time::HiRes has 'stat' before using it

    Doc Fixes:
    * RT#87350 Document DLEXT parameter (sisyphus)

10 years agoUpdate README copyright to 2013
Smylers [Fri, 6 Sep 2013 05:02:41 +0000 (06:02 +0100)]
Update README copyright to 2013

For RT #119625.

10 years agoPut AV defelem creation code in one place
Father Chrysostomos [Fri, 6 Sep 2013 07:51:16 +0000 (00:51 -0700)]
Put AV defelem creation code in one place

10 years agoUse defelems for (goto) &xsub calls
Father Chrysostomos [Fri, 6 Sep 2013 07:17:05 +0000 (00:17 -0700)]
Use defelems for (goto) &xsub calls

Before ce0d59f:

$ perl -e '++$#_; &utf8::encode'
Modification of a read-only value attempted at -e line 1.

As of ce0d59f:

$ ./perl -Ilib -e '++$#_; &utf8::encode'
Assertion failed: (sv), function Perl_sv_utf8_encode, file sv.c, line 3581.
Abort trap: 6

Calling sub { utf8::encode($_[0]) } should be more or less equivalent
to calling utf8::encode, but it is not in this case:

$ ./perl -Ilib -we '++$#_; &{sub { utf8::encode($_[0]) }}'
Use of uninitialized value in subroutine entry at -e line 1.

In the first two examples above, an implementation detail is leaking
through.  What you are seeing is not the array element, but a place-
holder that indicates an element that has not been assigned to yet.

We should use defelem magic so that what the XSUB assigns to will cre-
ate an array element (as happens with utf8::encode($_[0])).

All of the above applies to goto &xsub as well.

10 years agopp_hot.c:pp_aelem: Use _NN in one spot
Father Chrysostomos [Fri, 6 Sep 2013 03:33:00 +0000 (20:33 -0700)]
pp_hot.c:pp_aelem: Use _NN in one spot

This av can never be null here.  av_len will already have failed an
assertion if it is.

10 years agoMake pp_splice handle nonexistent array elements
Father Chrysostomos [Thu, 5 Sep 2013 21:39:47 +0000 (14:39 -0700)]
Make pp_splice handle nonexistent array elements

Commit ce0d59f changed AVs to use NULLs for nonexistent elements.

pp_splice needs to take that into account and avoid pushing NULLs on
to the stack.

10 years agoUpdate Time-Piece to CPAN version 1.23
Chris 'BinGOs' Williams [Fri, 6 Sep 2013 12:24:57 +0000 (13:24 +0100)]
Update Time-Piece to CPAN version 1.23

  [DELTA]

  1.23      2013-09-06
        - add a LICENSE file (thanks, John Peacock!)
        - make sure Time::Seconds loads Exporter, which it relies on (thanks,
          GFUJI and TOKUHIROM!)
        - fix day of year parsing (like "%y%j") (thanks, Doug Wilson)

10 years agomore Slavic intelligibility: added Bosnian to Serbian and Croatian
Slaven Rezic [Sat, 6 Feb 2010 22:55:31 +0000 (23:55 +0100)]
more Slavic intelligibility: added Bosnian to Serbian and Croatian

Bump $VERSION.

For: RT #72594

10 years agoStop autodie test from changing a file to stop Git whining about uncommitted changes
Steve Hay [Thu, 5 Sep 2013 17:11:07 +0000 (18:11 +0100)]
Stop autodie test from changing a file to stop Git whining about uncommitted changes

The patch has been sent upstream as CPAN#88444.

10 years agoperldelta - Add note about DynaLoader change (commit 1e5d7f5401)
Steve Hay [Thu, 5 Sep 2013 16:38:13 +0000 (17:38 +0100)]
perldelta - Add note about DynaLoader change (commit 1e5d7f5401)

10 years agoLocale::Codes has been upgraded from version 3.26 to 3.27
Steve Hay [Thu, 5 Sep 2013 16:30:05 +0000 (17:30 +0100)]
Locale::Codes has been upgraded from version 3.26 to 3.27

10 years agoPATCH: Bump Locale-Codes from 3.26 to 3.27
Sullivan Beck [Thu, 5 Sep 2013 13:21:52 +0000 (09:21 -0400)]
PATCH: Bump Locale-Codes from 3.26 to 3.27

I just released Locale-Codes-3.27 which contains the core modules
Locale::Country, Locale::Language, and Locale::Currency.  The patch is
attached here.

====
Background:

The core modules Locale::Country, Locale::Language, and
Locale::Currency(all part of the Locale-Codes distribution) should be
updated on aregular basis. They contain "codes" from various internet
standardswhich change over time.

I plan on releasing new versions at 4 times a year to keep the
codesup-to-date. At this point, I'm not planning on any significant
codechanges (other than bug fixes), so the only significant
changesbetween releases should be to update the codes.

>From 708ae6e6e8a6e839cb9510513b82ee95eec80260 Mon Sep 17 00:00:00 2001
From: Sullivan Beck <sbeck@cpan.org>
Date: Thu, 5 Sep 2013 09:12:04 -0400
Subject: [PATCH] Bump Locale-Codes from 3.26 to 3.27

Signed-off-by: Chris 'BinGOs' Williams <chris@bingosnet.co.uk>
10 years agoMake perltodo.pod match other deleted documents
Smylers [Thu, 5 Sep 2013 10:29:15 +0000 (11:29 +0100)]
Make perltodo.pod match other deleted documents

Have the title make clear it's now only a link to the to-do list.

Re-arrange the body content so the most useful thing — the link to the
current to-do list — is first and the history afterwards.

For RT #119615.

10 years agoAdd titles to deleted OO docs
Smylers [Thu, 5 Sep 2013 10:26:50 +0000 (11:26 +0100)]
Add titles to deleted OO docs

Helpful somebody who encounters these documents or their titles realize
they contain links to where current information can be found.

For RT #119615, based on Father Chrysostomos's comment in RT #119571.

10 years agoAdd missing word
Smylers [Thu, 5 Sep 2013 10:14:04 +0000 (11:14 +0100)]
Add missing word

For RT #119615.

10 years agoList deleted docs alphabetically
Smylers [Thu, 5 Sep 2013 10:01:53 +0000 (11:01 +0100)]
List deleted docs alphabetically

perlrepository was added at the end in 5edbc4ff, when I apparently failed
to notice the list was in alphabetical order.

For RT #119615.

10 years agoMultiple commits in 1 attachment in Patch Guide
Smylers [Thu, 5 Sep 2013 08:07:23 +0000 (09:07 +0100)]
Multiple commits in 1 attachment in Patch Guide

In the Super Quick Patch Guide, if a change involves multiple commits, put
them all in a single perlbug attachment.

Father Chrysostomos says it's easier like this, in a comment on
RT #119599.

It simplifies the instructions, and avoiding the need to mention mail
clients.

10 years agoutil.c:my_pclose: Use NULL in PL_fdpid
Father Chrysostomos [Thu, 5 Sep 2013 08:11:59 +0000 (01:11 -0700)]
util.c:my_pclose: Use NULL in PL_fdpid

PL_fdpid is an AV, and as of ce0d59f AVs use NULL for nonexist-
ent elements.

Without using NULL for deleted elements of PL_fdpid, we end up with
pipes appearing to be open after they have actually been closed.

I don’t know how to write a test for this, but it makes
Proc::ParallelLoop pass its tests.

10 years agoUpdate perlguts for the magic flags changes in 5.18
Father Chrysostomos [Thu, 5 Sep 2013 07:38:53 +0000 (00:38 -0700)]
Update perlguts for the magic flags changes in 5.18

10 years agoperlguts: Note that SvUTF8 is meaningful only after SvPV
Father Chrysostomos [Thu, 5 Sep 2013 07:33:01 +0000 (00:33 -0700)]
perlguts: Note that SvUTF8 is meaningful only after SvPV

10 years agoperlguts: consistent spaces after dots
Father Chrysostomos [Thu, 5 Sep 2013 07:22:31 +0000 (00:22 -0700)]
perlguts: consistent spaces after dots

It was inconsistent throughout.

10 years agoUpdate perlguts for NULL in AVs
Father Chrysostomos [Thu, 5 Sep 2013 07:03:32 +0000 (00:03 -0700)]
Update perlguts for NULL in AVs

10 years agoRemove references to GNU DLD from Configure and config.sh scripts.
Nicholas Clark [Fri, 23 Aug 2013 09:39:40 +0000 (11:39 +0200)]
Remove references to GNU DLD from Configure and config.sh scripts.

Specifically eliminated i_dld, a variable indicating that <dld.h> should be
included, and remove dld from the list of wanted libraries.

10 years agoRemove support for GNU DLD in DynaLoader.
Nicholas Clark [Thu, 5 Sep 2013 09:37:11 +0000 (11:37 +0200)]
Remove support for GNU DLD in DynaLoader.

GNU DLD was a library that provided dynamic linking on a.out based systems.
The last release was in 1996, and it has been superseded by dlopen.

10 years agoMove functions prematurely placed into mathoms back to utf8.c
Karl Williamson [Thu, 5 Sep 2013 04:31:01 +0000 (22:31 -0600)]
Move functions prematurely placed into mathoms back to utf8.c

These functions are still called by some CPAN-upstream modules, so can't
go into mathoms until those are fixed.  There are other changes needed
in these modules, so I'm deferring sending patching to their maintainers
until I know all the necessary changes.

10 years agoregcomp.c: Don't use mathoms function
Karl Williamson [Thu, 5 Sep 2013 04:26:07 +0000 (22:26 -0600)]
regcomp.c: Don't use mathoms function

utf8n_to_uvuni() is on its way out.  Instead, this code knows that the
UTF-8 it is looking at is valid (having been already checked earlier in
the regex compilation process), so use valid_utf8_to_uvchr().  This
allows us to get rid of a flag variable.

10 years agoperlapi: Remove newly obsolete statement
Karl Williamson [Thu, 5 Sep 2013 03:53:08 +0000 (21:53 -0600)]
perlapi: Remove newly obsolete statement

Since commit 010ab96b9b802bbf77168b5af384569e053cdb63, this function is
now longer a wrapper, so shouldn't be described as such.

10 years agoWhen sending an email manually so it can have multiple patches, point out
Smylers [Thu, 5 Sep 2013 01:39:33 +0000 (03:39 +0200)]
When sending an email manually so it can have multiple patches, point out
that Mutt can construct the email for you.

Obviously this isn't as generally relevant as the rest of the Guide, since
patchers will use many different mail clients. But it's a significant boon
for those who do use Mutt, and a very short addition to the Guide.

Mutt is singled out simply because it has this functionality; I suspect
that most other widely used mail clients don't.

Committer: Removed trailing whitespace.  Applied patch manually because other
lines in the file had been rebroken and patch no longer applied cleanly.

For: RT #119599

10 years agoMultiple commits in Super Quick Patch Guide
Smylers [Wed, 4 Sep 2013 11:37:36 +0000 (12:37 +0100)]
Multiple commits in Super Quick Patch Guide

How to use perlbug when a change is a series of commits, not a single
commit.

This is the advice RJBS gave me over IRC. Including it in the guide should
avoid him having to repeat the advice to others.

Committer: Added single quotes around one keyboard command.

For: RT #119599

10 years agoResetting a check out in Super Quick Patch Guide
Smylers [Wed, 4 Sep 2013 10:58:34 +0000 (11:58 +0100)]
Resetting a check out in Super Quick Patch Guide

Add advice so that somebody wishing to submit a second patch doesn't need
to throw away their perl check-out and start again.

Not knowing the 'git clean' step caught me out, and meant perl wouldn't
build for me. Nicholas helped me out. Adding this to the guide will
hopefully save Nicholas from having to repeat that for others (especially
since others may not be fortunate enough to have Nicholas handily seated
next to them at the point they encounter it).

(The non-building was because some things in the repository had been
re-arranged since my previous patch (several months earlier), and the
latest build was getting confused by some files left over from a
pre-re-arragned build.)

The 'git clean' step will also remove the first 0001-*.patch file, avoiding
the problem of there being two files matching that glob when attaching the
second patch.

Committer: Removed trailing whitespace.

For: RT #119599

10 years agoSuggest reading blead's Super Quick Patch Guide
Smylers [Wed, 4 Sep 2013 10:37:58 +0000 (11:37 +0100)]
Suggest reading blead's Super Quick Patch Guide

The Super Quick Patch Guide has been improved several times. Suggest that
a patcher looks at the latest version in the checkout of blead they've
just made, in case that's been improved since whichever released version
they were reading.

This has caught me out before: I've done something sub-optimal (for me or
those reviewing my patches) by diligently following out-of-date
instructions.

Remove trailing whitespace.

For: RT #119599

10 years agoperlbug command wrapped to fit in 79 columns
Smylers [Wed, 4 Sep 2013 09:54:15 +0000 (10:54 +0100)]
perlbug command wrapped to fit in 79 columns

To pass t/porting/podcheck.t --pedantic

The line-break is inside a $(...), so the lines can be copied-and-pasted
as they are, complete with line-break and extra spaces, and still give the
same output.

Remove trailing whitespace.

For: RT #119599

10 years agoHave perlbug report version being patched
Smylers [Wed, 4 Sep 2013 09:49:41 +0000 (10:49 +0100)]
Have perlbug report version being patched

In the Super Quick Patch Guide, run the perlbug and perl from the working
copy that the patch is against, so the bug report contains relevant
version and configuration data, rather than that of whichever system perl
the reporter happens to have installed.

For: RT #119599

10 years agoConsistent indent on shell commands
Smylers [Wed, 4 Sep 2013 10:32:24 +0000 (11:32 +0100)]
Consistent indent on shell commands

Most verbatim lines with shell commands had 2 spaces before the % prompt.
A few had 1 or 4 spaces. Make them all 2.

Remove trailing whitespace.

For: RT #119599

10 years agoperlhack.pod tidied
Smylers [Wed, 4 Sep 2013 09:31:25 +0000 (10:31 +0100)]
perlhack.pod tidied

In accordance with the comment at the top of the file, before I make other
changes to it.

Remove trailing whitespace.

For: RT #119599

10 years agoUpgrade Socket from version 2.011 to 2.012
Steve Hay [Wed, 4 Sep 2013 23:28:56 +0000 (00:28 +0100)]
Upgrade Socket from version 2.011 to 2.012

10 years agoThe bisect tool now takes test scripts as targets, and runs them with t/TEST
Nicholas Clark [Wed, 4 Sep 2013 11:20:37 +0000 (13:20 +0200)]
The bisect tool now takes test scripts as targets, and runs them with t/TEST

This makes it easier to bisect when test scripts started failing.

10 years ago[perl #119481] Check SvVALID for !SvSCREAM, skip PAD
Reini Urban [Tue, 27 Aug 2013 16:52:28 +0000 (11:52 -0500)]
[perl #119481] Check SvVALID for !SvSCREAM, skip PAD

SVpad_NAME = SVp_SCREAM|SVpbm_VALID
Subsequently OUR, TYPED and STATE pads all have SVp_SCREAM set.
SVpad_NAME shares the same bit with SVpbm_VALID, so avoid checking
PADs for SVpbm_VALID.

10 years agoRestore perlrepository.pod in stub form
Smylers [Tue, 3 Sep 2013 13:52:12 +0000 (14:52 +0100)]
Restore perlrepository.pod in stub form

Give Perl doc sites a sane ‘latest’ version to display, directing readers
to current information, rather than showing the Perl 5.12 version in
perpetuity.

And help anybody typing man perlrepository find where the docs have moved
to.

Suggested by Father Chrysostomos in:
http://www.nntp.perl.org/group/perl.perl5.porters/2013/09/msg207079.html

10 years agoCarp-1.32 has been released to CPAN
Zefram [Tue, 3 Sep 2013 19:00:22 +0000 (20:00 +0100)]
Carp-1.32 has been released to CPAN

10 years agoversion has been upgraded from version 0.9903 to 0.9904
Steve Hay [Tue, 3 Sep 2013 07:48:47 +0000 (08:48 +0100)]
version has been upgraded from version 0.9903 to 0.9904

10 years agoSync core with CPAN version.pm release
John Peacock [Mon, 2 Sep 2013 22:49:50 +0000 (18:49 -0400)]
Sync core with CPAN version.pm release

Remove pointless diag lines, which were more trouble than they were
worth.  Add code to ensure that SV's with magic are handled properly,
and include a test for it as well.  A couple of whitespace changes and
one last set of I32 -> SSize_t upgrade for array indices.

10 years agoAnother reason for home-grown kill() on VMS.
Craig A. Berry [Mon, 2 Sep 2013 21:19:41 +0000 (16:19 -0500)]
Another reason for home-grown kill() on VMS.

For some time now Perl has provided its own kill() function on VMS
due to various problems with the system-supplied one, notably that
when called from within a signal handler, the second signal never
got delivered.  This has at long last been corrected in the OS
as of the VMS84I_SYS V3.0 ECO.

But this exposes another problem with the CRTL's kill(), which is
that when called with a signal value of 0 it actually kills the
running program instead of restricting itself to error checking
as the standard requires.  This turns out to be documented behavior
and the documented workaround is to define the _POSIX_EXIT macro.

However, universally changing the behavior of the exit() function
in order to prevent

  kill(getpid(),0);

from bringing down the program that calls it doesn't seem like the
right trade-off.  So just add one more condition to the list of
conditions under which we'll use our own kill().

10 years agotoke.c: Clarify comment
Karl Williamson [Mon, 2 Sep 2013 17:17:13 +0000 (11:17 -0600)]
toke.c: Clarify comment

10 years agot/op/for.t: Skip a test if the require for XS::APItest fails
Brian Fraser [Mon, 2 Sep 2013 17:07:53 +0000 (14:07 -0300)]
t/op/for.t: Skip a test if the require for XS::APItest fails

10 years agoDon’t assume targs are contiguous for ‘my $x; my $y’
Father Chrysostomos [Mon, 2 Sep 2013 15:29:50 +0000 (08:29 -0700)]
Don’t assume targs are contiguous for ‘my $x; my $y’

In commit 18c931a3, the padrange optimisation was prevented from mak-
ing this assumption for ‘my ($x,$y)’, but the assumption was still
there in the code that combines multiple statements into one.

This would lead to assertion failures (or, as of ce0d59f, crashes
under non-debugging builds) if a keyword plugin declined to handle
the second ‘my’, but only after creating a padop.

This fixes a regression from 5.16 affecting Devel::CallParser under
threaded builds.