This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perl5.git
12 years ago...and add unadded file
Ricardo Signes [Sun, 19 Feb 2012 14:55:02 +0000 (09:55 -0500)]
...and add unadded file

12 years agoremove MANIFEST entries for pruned files
Ricardo Signes [Sun, 19 Feb 2012 14:29:52 +0000 (09:29 -0500)]
remove MANIFEST entries for pruned files

12 years agoRefactor the Tk event loop to allow for other event loops
Max Maischein [Sun, 19 Feb 2012 13:09:55 +0000 (14:09 +0100)]
Refactor the Tk event loop to allow for other event loops

Term::ReadLine supports any event loop, including unpubished ones and
simple IO::Select loops without the need to rewrite existing code for
any particular framework.

12 years agoIn S_validate_suid(), move declarations after the first statement.
Nicholas Clark [Sun, 19 Feb 2012 08:38:52 +0000 (09:38 +0100)]
In S_validate_suid(), move declarations after the first statement.

Otherwise exacting C89 compilers refuse to build the code. And at least
one Win32 compiler is exacting on this.

12 years agoRefactor code in Data::Dumper to assume that >=5.8.0 is the common case.
Nicholas Clark [Sat, 18 Feb 2012 14:01:32 +0000 (15:01 +0100)]
Refactor code in Data::Dumper to assume that >=5.8.0 is the common case.

The 5.8.0 versions of &init_refaddr_format and &format_refaddr are now
compiled by default, and then redefined with their 5.6.x replacements if
it turns out that we're on 5.6.1 or 5.6.2.

Previously both versions were compiled, and the correct pair bound using
typeglob assignment.

12 years agoFix typo in 985213f2fede57.
Craig A. Berry [Sun, 19 Feb 2012 05:06:16 +0000 (23:06 -0600)]
Fix typo in 985213f2fede57.

Which broke the build on both VMS and Win32.

12 years agoRemove gete?[ug]id caching
Ævar Arnfjörð Bjarmason [Sun, 12 Feb 2012 18:56:35 +0000 (18:56 +0000)]
Remove gete?[ug]id caching

Currently we cache the UID/GID and effective UID/GID similarly to how
we used to cache getpid() before v5.14.0-251-g0e21945. Remove this
magical behavior in favor of always calling getpid(), getgid()
etc. This resolves RT #96208.

A minimal testcase for this is the following by Leon Timmermans
attached to RT #96208:

    eval { require 'syscall.ph'; 1 } or eval { require 'sys/syscall.ph'; 1 } or die $@;

    if (syscall(&SYS_setuid, $ARGV[0] + 0 || 1000) >= 0 or die "$!") {
            printf "\$< = %d, getuid = %d\n", $<, syscall(&SYS_getuid);
    }

I.e. if we call the sete?[ug]id() functions unbeknownst to perl the
$<, $>, $( and $) variables won't be updated. This results in the same
sort of issues we had with $$ before v5.14.0-251-g0e21945, and
getppid() before my v5.15.7-407-gd7c042c patch.

I'm completely eliminating the PL_egid, PL_euid, PL_gid and PL_uid
variables as part of this patch, this will break some CPAN modules,
but it'll be really easy before the v5.16.0 final to reinstate
them. I'd like to remove them to see what breaks, and how easy it is
to fix it.

These variables are not part of the public API, and the modules using
them could either use the Perl_gete?[ug]id() functions or are working
around the bug I'm fixing with this commit.

The new PL_delaymagic_(egid|euid|gid|uid) variables I'm adding are
*only* intended to be used internally in the interpreter to facilitate
the delaymagic in Perl_pp_sassign. There's probably some way not to
export these to programs that embed perl, but I haven't found out how
to do that.

12 years agoAdd t/porting/pending-author.t, fixing a limitation of t/porting/authors.t
Nicholas Clark [Wed, 15 Feb 2012 16:26:53 +0000 (17:26 +0100)]
Add t/porting/pending-author.t, fixing a limitation of t/porting/authors.t

t/porting/pending-author.t attempts to avoid the problem of C<make test>
passing 100%, but the subsequent git commit causing F<t/porting/authors.t>
to fail, because it uses a "new" e-mail address.

This test is only run if one is building inside a git checkout, B<and> one
has made local changes. Otherwise it's skipped.

12 years agot/porting/authors.t only needs to pass the Author to checkAUTHORS.pl
Nicholas Clark [Wed, 15 Feb 2012 15:11:42 +0000 (16:11 +0100)]
t/porting/authors.t only needs to pass the Author to checkAUTHORS.pl

Commit 3ea0c581844689ab didn't go far enough in pruning the input.
When Porting/checkAUTHORS.pl is invoked with --tap it uses
parse_commits_from_stdin_authors() instead of parse_commits_from_stdin(),
which only looks for lines matching /^Author:/

This reduces runtime by a further 8%.

12 years agoCorrect the location of t/porting/perlfunc.t in perldelta.pod
Nicholas Clark [Sat, 18 Feb 2012 22:10:05 +0000 (23:10 +0100)]
Correct the location of t/porting/perlfunc.t in perldelta.pod

It was somewhere completely wrong, thanks to no human double checking of
a git rebase during development.

12 years agoLonger filenames for while_readdir.t.
Craig A. Berry [Sat, 18 Feb 2012 21:10:19 +0000 (15:10 -0600)]
Longer filenames for while_readdir.t.

With filenames varying between only one and five characters in
length, it was fairly easy to get two files differing only in
case ('A' and 'a', for example).  Which on non-case-sensitive file
systems could generate a warning at unlink time because it would
unlink 'a' and then check for the existence of 'a' and get true
because 'A' was still there and indistinguishable from 'a'.

So just use longer filenames to make the possibility of collision
vanishingly small.

12 years agoperlvar: $] is not deprecated
Father Chrysostomos [Sat, 18 Feb 2012 19:16:31 +0000 (11:16 -0800)]
perlvar: $] is not deprecated

See <20011022034838.B1676@blackrider> and commit 0c8d858bc.

12 years agoUpdate IO-Compress to CPAN version 2.049
Chris 'BinGOs' Williams [Sat, 18 Feb 2012 16:24:52 +0000 (16:24 +0000)]
Update IO-Compress to CPAN version 2.049

  [DELTA]

  2.049 18 February 2012

      * IO::Compress::Zip
        Error in t/cz-03zlib-v1.t that caused warnings with 5.15
        [RT# 110736: warnings from cpan/IO-Compress/t/cz-03zlib-v1.t]

12 years agoUpdate Compress-Raw_Zlib to CPAN version 2.049
Chris 'BinGOs' Williams [Sat, 18 Feb 2012 16:22:43 +0000 (16:22 +0000)]
Update Compress-Raw_Zlib to CPAN version 2.049

  [DELTA]

  2.049 30 January 2012

      * Include zlib 1.2.6 source.

12 years agoUpdate Compress-Raw-Bzip2 to CPAN version 2.049
Chris 'BinGOs' Williams [Sat, 18 Feb 2012 16:18:48 +0000 (16:18 +0000)]
Update Compress-Raw-Bzip2 to CPAN version 2.049

  [DELTA]

  2.049 18 February 2012

      * No Changes

12 years agoUpdate perlfaq to CPAN version 5.0150039
Chris 'BinGOs' Williams [Sat, 18 Feb 2012 15:50:37 +0000 (15:50 +0000)]
Update perlfaq to CPAN version 5.0150039

  [DELTA]

  5.0150039 Sat 18 Feb 2012 15:33:17 +0100
    * Rewrite "How do I create a module?" (ranguard)
    * Remove more old questions (ranguard)
    * Improve Email::MIME example (madsen)
    * Fix to regex (RT #74215)

12 years agopopulate the Future Deprecations section
Ricardo Signes [Thu, 16 Feb 2012 23:45:46 +0000 (18:45 -0500)]
populate the Future Deprecations section

These items aggregate the bullets put forth on the perl5-porters
list, omitting those to which there was an immediate objection.

12 years agoMerge the Pod::Functions refactoring to blead.
Nicholas Clark [Sat, 18 Feb 2012 12:23:26 +0000 (13:23 +0100)]
Merge the Pod::Functions refactoring to blead.

12 years agoDescribe the update to Pod::Functions in perldelta.
Nicholas Clark [Fri, 17 Feb 2012 20:36:31 +0000 (21:36 +0100)]
Describe the update to Pod::Functions in perldelta.

12 years agoAdd metadata to perlfunc.pod for which version or feature added a function.
Nicholas Clark [Tue, 14 Feb 2012 12:41:07 +0000 (13:41 +0100)]
Add metadata to perlfunc.pod for which version or feature added a function.

Whilst this isn't used (yet), it makes sense to put it in now, before any
external program decides that parsing the private Pod::Function blocks in
perlfunc.pod is fair game, and then becomes dependent on their format.

12 years agoTest that Pod::Function's descriptions are stylistically consistent.
Nicholas Clark [Tue, 14 Feb 2012 12:34:56 +0000 (13:34 +0100)]
Test that Pod::Function's descriptions are stylistically consistent.

Function descriptions should start with a lowercase letter, or the proper
noun SysV.

12 years agoTest that functions in the groups in perlfunc.pod are in sorted order.
Nicholas Clark [Mon, 30 Jan 2012 19:05:33 +0000 (20:05 +0100)]
Test that functions in the groups in perlfunc.pod are in sorted order.

This ensures consistency in the documentation, and that the functions in
%Pod::Functions::Kinds are in sorted order.

12 years agoTest that every function in perlfunc.pod has a summary for Pod::Functions.
Nicholas Clark [Mon, 30 Jan 2012 17:41:54 +0000 (18:41 +0100)]
Test that every function in perlfunc.pod has a summary for Pod::Functions.

Historically Pod::Functions has failed to get updated when functions are
added. This should solve that.

12 years agoAdd t/porting/perlfunc.t so that porting tests catch problems with perlfunc
Nicholas Clark [Mon, 30 Jan 2012 13:47:13 +0000 (14:47 +0100)]
Add t/porting/perlfunc.t so that porting tests catch problems with perlfunc

Pod::Functions is now generated from pod/perlfunc.pod by
ext/Pod-Functions/Functions_pm.PL

If it can't parse pod/perlfunc.pod, it will abort, which will cause the
build to break. It's really not possible for it to carry on, hence aborting
is the only option. However, innocent-seeming changes to documentation
shouldn't break the build, and we expect everyone to run (at least)
the porting tests, hence this test, to catch such problems before it's too
late. To avoid duplicating the parsing logic, we make Functions_pm.PL take
a --tap option, to test that all is well.

12 years agoIn the generated Pod::Functions, store all function data with tab separation.
Nicholas Clark [Mon, 30 Jan 2012 11:27:40 +0000 (12:27 +0100)]
In the generated Pod::Functions, store all function data with tab separation.

Previously the data was stored with a comma separated list inside a tab
separated list.

12 years agoGenerate Pod::Functions from perlfunc.pod
Nicholas Clark [Mon, 30 Jan 2012 11:15:36 +0000 (12:15 +0100)]
Generate Pod::Functions from perlfunc.pod

This avoids it getting out of synchronisation.

12 years agoAdd a dependency for ext/Pod-Functions/Functions_pm.PL on pod/perlfunc.pod
Nicholas Clark [Mon, 30 Jan 2012 11:01:08 +0000 (12:01 +0100)]
Add a dependency for ext/Pod-Functions/Functions_pm.PL on pod/perlfunc.pod

This ensures that it gets re-run, and lib/Pod/Functions.pm rebuilt, if
perlfunc.pod is changed.

12 years agoEnsure Pod::Simple is built before Pod::Functions.
Nicholas Clark [Mon, 30 Jan 2012 10:41:13 +0000 (11:41 +0100)]
Ensure Pod::Simple is built before Pod::Functions.

This will allow Pod::Functions to use Pod::Simple as part of its build
process.

12 years agoChange ext/Pod-Functions to generate Functions.pm from a Perl script.
Nicholas Clark [Sun, 29 Jan 2012 17:21:27 +0000 (17:21 +0000)]
Change ext/Pod-Functions to generate Functions.pm from a Perl script.

For the first step, simply output the current file in one hit.

12 years agoAdd annotations to perlfunc.pod for Pod::Functions.
Nicholas Clark [Sun, 29 Jan 2012 14:56:01 +0000 (14:56 +0000)]
Add annotations to perlfunc.pod for Pod::Functions.

In the list for "Perl Functions by Category" each item is annotated with its
type as used internally by Pod::Functions.

In the "Alphabetical Listing of Perl Functions" each function is annotated
with the summary description returned by %Pod::Functions::Flavor.

12 years agoMove Pod::Functions from lib/ to ext/
Nicholas Clark [Sun, 29 Jan 2012 13:00:41 +0000 (13:00 +0000)]
Move Pod::Functions from lib/ to ext/

12 years agoBring the joy of strict and warnings to Functions.t
Nicholas Clark [Sun, 29 Jan 2012 12:23:31 +0000 (12:23 +0000)]
Bring the joy of strict and warnings to Functions.t

This reveals that use_ok() was not in a BEGIN block, and in turn that the
test count needs to be declared before this BEGIN block runs. Now fixed.

12 years agoTerser code in Pod::Functions to generate $Type_Description and @Type_Order.
Nicholas Clark [Sun, 29 Jan 2012 12:06:05 +0000 (12:06 +0000)]
Terser code in Pod::Functions to generate $Type_Description and @Type_Order.

12 years agoTeach Pod::Functions that each, keys and values also operate on arrays.
Nicholas Clark [Mon, 23 Jan 2012 22:38:43 +0000 (23:38 +0100)]
Teach Pod::Functions that each, keys and values also operate on arrays.

These were added to the section 'Functions for real @ARRAYs' in perlfunc.pod
by commit a5ce339cb0c533c9 in Sep 2010.

As ever, tweak the golden results in the test to match these changes.

12 years agoAdd all missing functions to Pod::Functions.
Nicholas Clark [Mon, 23 Jan 2012 22:16:56 +0000 (23:16 +0100)]
Add all missing functions to Pod::Functions.

evalbytes was added to perlfunc.pod by commit 7289c5e6ca773d7c in Nov 2011.
fc was added to perlfunc.pod by commit 628253b8ba8b9cbe in Jan 2012.
say was added by commit 0d863452f5cac863 in Dec 2005.
state was added.pod by commit 36fb85f3330d45ee in Jul 2006.
__FILE__, __LINE__ and __PACKAGE__ were added by commit cfa52385fa426b5e in
Aug 2011, and __SUB__ by commit 84ed01088568ffe9 in Nov 2011.

Again, tweak the golden results in the test to match these changes.

12 years agoTeach Pod::Functions about 'Keywords related to the switch feature'.
Nicholas Clark [Mon, 23 Jan 2012 21:44:52 +0000 (22:44 +0100)]
Teach Pod::Functions about 'Keywords related to the switch feature'.

Commit 0d863452f5cac863 in Dec 2005 added the switch feature, along with
documentation in perlfunc.pod, but did not update Pod::Functions.

Again, tweak the golden results in the test to match these changes.

12 years agoUpdate Pod::Functions with changes from perlfunc.pod
Nicholas Clark [Mon, 23 Jan 2012 20:47:16 +0000 (21:47 +0100)]
Update Pod::Functions with changes from perlfunc.pod

Updated description of Binary from commit 5dac7880bdc47787 in Feb 2011.
Updated description of Flow from commit cf2649810f00335b in Jul 2005, and
added the "the" which has always been missing from Pod::Function's version.
Updated description of Modules from commit 3b10bc60979cfe9a in Jan 2010.
Updated description of Objects from commit 353c650532037e40 in Oct 2007.
The description of Namespaces had always differed from that in perlfunc.pod.

Remove stray tabs from the descriptions of gets and sprintf.
Commit 19799a22062ef658 (May 1999) added lock to perlfunc.pod without a
it is the only function in "Threads", move it to "Misc", instead of creating
a category just for it.
use always had two entries with different descriptions in the __DATA__
section. This isn't actually sensible, as the code that builds the exported
data structures ends up taking Types from both, and using the last
description that it sees. So merge the two together to reflect this.

Drop the CHANGES section from the Pod, which is both incomplete and
redundant, given that version control does this job much better.

Tweak the golden results in the test to match these changes.

12 years agoIn perlfunc.pod, sort the descriptions more consistently.
Nicholas Clark [Mon, 23 Jan 2012 16:51:48 +0000 (17:51 +0100)]
In perlfunc.pod, sort the descriptions more consistently.

The order is neither strictly lexical, nor strictly dictionary, but now for
all cases __FOO__ follows foo, and qx// is after qw//.

In the "Regular expressions and pattern matching" summary, put qr// in the
correct position alphabetically.

12 years agoAdd 4 functions missing from perlfunc.pod's 'Perl Functions by Category'.
Nicholas Clark [Mon, 23 Jan 2012 16:32:17 +0000 (17:32 +0100)]
Add 4 functions missing from perlfunc.pod's 'Perl Functions by Category'.

C<readline> added to 'Input and output functions'
Documentation on readline was added by commit 8490252049bf42d3 in Aug 1997.
That commit also added readpipe without adding it to a category group, an
omission that was fixed by commit 4319b00c03e6a517 in Nov 2011.

C<sysseek> added to 'Functions for fixed-length data or records'
Documentation on sysseek was added by commit 137443ea0a858c43 in Apr 1997,
which implemented sysseek.

C<prototype> added to both 'Keywords related to the control flow of your Perl
program' and 'Miscellaneous functions', as Pod::Functions places it in both.
Commit da0045b73af6f504 in Jul 1996, included 'Add documentation for new
"prototype" operator', but only added the main documentation, not an entry
in a category group.

C<lock> added to 'Miscellaneous functions'.
Documentation on lock was added by commit 19799a22062ef658 in May 1999.

12 years agocorrectly clone eval context frames
Zefram [Sat, 18 Feb 2012 11:31:48 +0000 (11:31 +0000)]
correctly clone eval context frames

When cloning stacks (only used for Win32 fork emulation, not for ordinary
threads), the CV referenced by an eval context frame wasn't being cloned.
This led to crashes when Win32 forked inside an eval [perl #109718].

12 years agoRevert "Increase the fallback value of MAXPATHLEN"
Dominic Hargreaves [Fri, 3 Feb 2012 19:40:30 +0000 (19:40 +0000)]
Revert "Increase the fallback value of MAXPATHLEN"

This reverts commit ffa23acf6bf9670bd1d5fdc9a958c918b6cf3d06.

This change was made without realisation that the fallback value for
MAXPATHLEN on POSIX systems comes (in perl.h) from _POSIX_MAX_PATH,
so the fallback value here was not used.

12 years ago[perl #109262] Don't use _POSIX_PATH_MAX as a fallback PATH_MAX
Dominic Hargreaves [Fri, 3 Feb 2012 19:35:36 +0000 (19:35 +0000)]
[perl #109262] Don't use _POSIX_PATH_MAX as a fallback PATH_MAX

_POSIX_PATH_MAX is required to be defined for POSIX systems as
256, which is too small for a fallback PATH_MAX (some systems, such as
GNU/Hurd, do not have an inherent limit on path length).

12 years agoFilter-1.40 released to CPAN
Reini Urban [Sat, 18 Feb 2012 05:09:23 +0000 (23:09 -0600)]
Filter-1.40 released to CPAN

Also clarify cpan as upstream

12 years agoBump Cwd, File::Spec version.
Craig A. Berry [Sat, 18 Feb 2012 03:31:26 +0000 (21:31 -0600)]
Bump Cwd, File::Spec version.

12 years agoRethink EFS in File::Spec::VMS.
Craig A. Berry [Fri, 17 Feb 2012 23:31:59 +0000 (17:31 -0600)]
Rethink EFS in File::Spec::VMS.

ae5a807c7dcf made extensive changes to File::Spec on VMS, nominally
to support Extended Filename Syntax (EFS).  The idea behind the
changes was that with EFS in effect, the File::Spec functions can
guess at whether incoming file specifications are in Unix format
or VMS format and provide output in the same format as the input.

This principle is in some ways desireable in that round-trip
conversions do have the potential to lose information and it
sounds like a nice bit of DWIMmery. However, in practice it leads
to its being a crap shoot what format you'll get back, and in some
really important cases (such as MakeMaker's assembly of paths for
external build utilities) you really have to know which syntax you
have and you may really have to have native syntax, which has
always been the default.

It's also impossible to guess in some of the more common use cases,
such as a splitdir followed by catdir, where catdir has no way of
knowing what delimiters were discarded by splitdir, and thus no
hints about what syntax the original path was in.

Plus there were numerous problems with the implementation, which
broke the build when EFS was in effect and didn't pass very many
of its own tests (which it had inadvertently disabled, since fixed
in 06ecd9c7d6f).

Plus EFS isn't primarily about Unix syntax versus VMS syntax but
about allowing additional characters, such as multiple dots in
filenames or any dots in directory names.  The only real difference
for the File::Spec functions should be that they now need to avoid
splitting on traditional delimiters if those characters are escaped
with the caret (^) character.

So revert most of ae5a807c7dcf, and sprinkle negative look-behind
assertions liberally so that we correctly recognize when
traditional delimiters have been escaped and are not being used
as delimiters.

The partial support for Unix reporting mode (where we explicitly
request that output file specifications are in Unix format
regardless of input format) is left in place.  It's somewhat less
partial than it was, but still incomplete.

12 years agoThere is no G_LIST, only G_ARRAY
Florian Ragwitz [Fri, 17 Feb 2012 20:15:17 +0000 (21:15 +0100)]
There is no G_LIST, only G_ARRAY

12 years agoprune faulty dead logic in pp_flock
Zefram [Fri, 17 Feb 2012 21:24:13 +0000 (21:24 +0000)]
prune faulty dead logic in pp_flock

pp_flock had code to implicitly use the "last read" I/O handle if invoked
with no arguments.  Actually both of its arguments are mandatory, so this
could never be reached.  It was presumably cargo-culted from another op
such as pp_tell.

12 years agomake regen
Father Chrysostomos [Thu, 16 Feb 2012 21:42:56 +0000 (13:42 -0800)]
make regen

12 years agofix -Uuserelocatableinc
Reini Urban [Wed, 8 Feb 2012 19:22:11 +0000 (13:22 -0600)]
fix -Uuserelocatableinc

-Uuserelocatableinc resulted in PERL_RELOCATABLE_INC defined as "undef" which is defined

12 years agobisect.pl now reports a meaningful error for certain "can't start" scenarios.
Nicholas Clark [Fri, 17 Feb 2012 17:36:55 +0000 (18:36 +0100)]
bisect.pl now reports a meaningful error for certain "can't start" scenarios.

If --end is specified but not --start, then don't probe for start revisions
that are more recent than the --end. Previously bisect.pl would test all
stable revisions for a start point, and if it happened to find a (seemingly)
valid start point, it would continue on to run git bisect, which would fail
with the error:

    Some good revs are not ancestor of the bad rev.
    git bisect cannot work properly in this case.
    Maybe you mistake good and bad revs?

which doesn't make clear what the problem actually is. Now the error is:

    Can't find a suitable start revision to default to.
    Tried perl-5.002 perl-5.003 perl-5.004 perl-5.005 perl-5.6.0 at ...

12 years agoVMS does have sockaddr_in6 and ipv6_mreq.
Craig A. Berry [Fri, 17 Feb 2012 18:18:58 +0000 (12:18 -0600)]
VMS does have sockaddr_in6 and ipv6_mreq.

Or at least has had for 10 years or more.  If someone shows up
wanting to build on an older system, we can add real probes.

Plus we can't write to config.sh before it's been opened, as
18126d98dd7 had us doing.

12 years agoFor make test, move the 'porting' tests before 'lib', 'ext', 'dist' & 'cpan'
Nicholas Clark [Fri, 17 Feb 2012 15:13:05 +0000 (16:13 +0100)]
For make test, move the 'porting' tests before 'lib', 'ext', 'dist' & 'cpan'

This makes the order more consistent with test_harness, and moves the
"interesting" tests earlier. "interesting", in that these are more likely
to spot unexpected problems with the tested changes.

12 years agoIn Perl_sv_del_backref(), don't panic if tsv is already freed.
Nicholas Clark [Thu, 16 Feb 2012 22:20:53 +0000 (23:20 +0100)]
In Perl_sv_del_backref(), don't panic if tsv is already freed.

During global destruction it's possible for tsv, the target of this weak
reference, to already be freed. This isn't a bug, and hence the interpreter
should not panic.

12 years agoUpdate Socket to CPAN version 1.98
Chris 'BinGOs' Williams [Thu, 16 Feb 2012 16:28:35 +0000 (16:28 +0000)]
Update Socket to CPAN version 1.98

  [DELTA]

  1.98  CHANGES:
         * Detect presence of sockaddr_in6 and ipv6_mreq; conditionally build
           pack/unpack functions on this
         * Back-compatibility improvements for older perls, back as far as
           5.6.1 (thanks Zefram)
         * Fix for picky compilers or platforms on which size_t doesn't
           printf() correctly by %d
         * Suppress some harmless compile-time warnings about unused variables

12 years agoCarp-1.25 released to CPAN
Zefram [Fri, 17 Feb 2012 09:24:17 +0000 (09:24 +0000)]
Carp-1.25 released to CPAN

12 years agoin Carp, cope with "_" in $warnings::VERSION
Zefram [Fri, 17 Feb 2012 09:20:49 +0000 (09:20 +0000)]
in Carp, cope with "_" in $warnings::VERSION

The check for very old versions of warnings was generating a numeric
warning on some versions of warnings where $warnings::VERSION isn't a
proper number.  Oh, the irony.  Specifically affected the version of
warnings that was bundled with Perl 5.8.9.

12 years agoAdd new probes for IPv6 (LeoNerd)
H.Merijn Brand [Thu, 16 Feb 2012 16:17:18 +0000 (17:17 +0100)]
Add new probes for IPv6 (LeoNerd)

12 years agobegin filling the 5.16.0 delta from 5.15.7
Ricardo Signes [Thu, 16 Feb 2012 03:49:36 +0000 (22:49 -0500)]
begin filling the 5.16.0 delta from 5.15.7

This is largely a copy and paste job.  Once I copy and paste most
things in, I will then start condensing them.

This does *not* include the following sections from perl5157delta:

* module updates
* configuration and compilation changes

12 years agobegin filling the 5.16.0 delta from 5.15.6
Ricardo Signes [Thu, 16 Feb 2012 03:39:47 +0000 (22:39 -0500)]
begin filling the 5.16.0 delta from 5.15.6

This is largely a copy and paste job.  Once I copy and paste most
things in, I will then start condensing them.

This does *not* include the following sections from perl5156delta:

* module updates
* internals changes

12 years agobegin filling the 5.16.0 delta from 5.15.5
Ricardo Signes [Thu, 16 Feb 2012 03:20:31 +0000 (22:20 -0500)]
begin filling the 5.16.0 delta from 5.15.5

This is largely a copy and paste job.  Once I copy and paste most
things in, I will then start condensing them.

This does *not* include the following sections from perl5155delta:

* module updates
* configuration and compilation changes
* internals changes

12 years agobegin filling the 5.16.0 delta from 5.15.4
Ricardo Signes [Thu, 16 Feb 2012 03:10:09 +0000 (22:10 -0500)]
begin filling the 5.16.0 delta from 5.15.4

This is largely a copy and paste job.  Once I copy and paste most
things in, I will then start condensing them.

This does *not* include the following sections from perl5154delta:

* module updates
* configuration and compilation changes
* internals changes

12 years agobegin filling the 5.16.0 delta from 5.15.3
Ricardo Signes [Thu, 16 Feb 2012 02:55:56 +0000 (21:55 -0500)]
begin filling the 5.16.0 delta from 5.15.3

This is largely a copy and paste job.  Once I copy and paste most
things in, I will then start condensing them.

This does *not* include the following sections from perl5153delta:

* module updates

12 years agoSimplify VMS symlink override.
Craig A. Berry [Thu, 16 Feb 2012 02:39:16 +0000 (20:39 -0600)]
Simplify VMS symlink override.

The implementation assumed that the CRTL's requirement to specify
the target name in Unix syntax is somehow related to EFS (Extended
Filename Syntax).  It isn't, so remove that assumption and simplify
the implementation.  Bug introduced by 4148925f.

12 years agoperldelta: Some char names now obsoleted
Karl Williamson [Thu, 16 Feb 2012 02:22:37 +0000 (19:22 -0700)]
perldelta: Some char names now obsoleted

Since I wrote the revision to perldelta about changing the names for the
four controls whose previous preferred name each contained parentheses,
the Unicode Technical Committee has voted to mark the old names as
obsolete.  This just updates the text to reflect that.

12 years agopp.c: Cast function argument to expected type
Karl Williamson [Thu, 16 Feb 2012 01:52:38 +0000 (18:52 -0700)]
pp.c: Cast function argument to expected type

This was breaking some builds

12 years agopp_quote_meta: in locale, quote all UTF-8 Latin1 non-ASCII
Karl Williamson [Wed, 15 Feb 2012 19:27:23 +0000 (12:27 -0700)]
pp_quote_meta: in locale, quote all UTF-8 Latin1 non-ASCII

Under locale rules, this commit quotes all non-ASCII Latin1 characters
in UTF-8 encoded strings.  This provides consistency with this function
and other functions, such as lc().

12 years agopp.c: white-space only
Karl Williamson [Wed, 15 Feb 2012 19:07:01 +0000 (12:07 -0700)]
pp.c: white-space only

12 years agoperl #77654: quotemeta quotes non-ASCII consistently
Karl Williamson [Wed, 15 Feb 2012 18:31:27 +0000 (11:31 -0700)]
perl #77654: quotemeta quotes non-ASCII consistently

As described in the pod changes in this commit, this changes quotemeta()
to consistenly quote non-ASCII characters when used under
unicode_strings.  The behavior is changed for these and UTF-8 encoded
strings to more closely align with Unicode's recommendations.

The end result is that we *could* at some future point start using other
characters as metacharacters than the 12 we do now.

12 years agopp_quotemeta(): Use more explicit macro
Karl Williamson [Wed, 15 Feb 2012 17:04:10 +0000 (10:04 -0700)]
pp_quotemeta(): Use more explicit macro

Changing the macro to a differently-named equivalent stresses that only
ASCII characters may escape from being quoted.  That is, all non-ASCII
are quoted.

12 years agohandy.h: New macro for quotemeta
Karl Williamson [Tue, 14 Feb 2012 01:51:34 +0000 (18:51 -0700)]
handy.h: New macro for quotemeta

This tests if a Latin1 character should be quoted.

12 years agol1_char_class_tab.h: Add field for quotemeta
Karl Williamson [Tue, 14 Feb 2012 01:48:59 +0000 (18:48 -0700)]
l1_char_class_tab.h: Add field for quotemeta

This changes this header to include a bit for each character indicating
if it should be quoted by quotemeta under unicode_strings

12 years agomktables: Generate a table for quotemeta
Karl Williamson [Tue, 14 Feb 2012 01:47:20 +0000 (18:47 -0700)]
mktables: Generate a table for quotemeta

This adds a new table generated by mktables consisting of the code
points that should be escaped by quotemeta

12 years agoClarify some quotemeta docs
Karl Williamson [Tue, 14 Feb 2012 01:44:35 +0000 (18:44 -0700)]
Clarify some quotemeta docs

12 years agoperlfunc: quotemeta, clarify, fix incorrect statement
Karl Williamson [Sun, 12 Feb 2012 15:14:34 +0000 (08:14 -0700)]
perlfunc: quotemeta, clarify, fix incorrect statement

12 years agoFurther eliminate POSIX-emulation under LinuxThreads
Ævar Arnfjörð Bjarmason [Sat, 11 Feb 2012 17:17:31 +0000 (17:17 +0000)]
Further eliminate POSIX-emulation under LinuxThreads

Under POSIX threads the getpid() and getppid() functions return the
same values across multiple threads, i.e. threads don't have their own
PID's. This is not the case under the obsolete LinuxThreads where each
thread has a different PID, so getpid() and getppid() will return
different values across threads.

Ever since the first perl 5.0 we've returned POSIX-consistent
semantics for $$, until v5.14.0-251-g0e21945 when the getpid() cache
was removed. In 5.8.1 Rafael added further explicit POSIX emulation in
perl-5.8.0-133-g4d76a34 [1] by explicitly caching getppid(), so that
multiple threads would always return the same value.

I don't think all this effort to emulate POSIX sematics is worth it. I
think $$ and getppid() are OS-level functions that should always
return the same as their C equivalents. I shouldn't have to use a
module like Linux::Pid to get the OS version of the return values.

This is pretty much a complete non-issue in practice these days,
LinuxThreads was a Linux 2.4 thread implementation that nobody
maintains anymore[2], all modern Linux distros use NPTL threads which
don't suffer from this discrepancy. Debian GNU/kFreeBSD does use
LinuxThreads in the 6.0 release, but they too will be moving away from
it in future releases, and really, nobody uses Debian GNU/kFreeBSD
anyway.

This caching makes it unnecessarily tedious to fork an embedded Perl
interpreter. When someone that constructs an embedded perl interpreter
and forks their application, the fork(2) system call isn't going to
run Perl_pp_fork(), and thus the return value of $$ and getppid()
doesn't reflect the current process. See [3] for a bug in uWSGI
related to this, and Perl::AfterFork on the CPAN for XS code that you
need to run after forking a PerlInterpreter unbeknownst to perl.

We've already been failing the tests in t/op/getpid.t on these Linux
systems that nobody apparently uses, the Debian GNU/kFreeBSD users did
notice and filed #96270, this patch fixes that failure by changing the
tests to test for different behavior under LinuxThreads, I've tested
that this works on my Debian GNU/kFreeBSD 6.0.4 virtual machine.

If this change is found to be unacceptable (i.e. we want to continue
to emulate POSIX thread semantics for the sake of LinuxThreads) we
also need to revert v5.14.0-251-g0e21945, because currently we're only
emulating POSIX semantics for getppid(), not getpid(). But I don't
think we should do that, both v5.14.0-251-g0e21945 and this commit are
awesome.

This commit includes a change to embedvar.h made by "make
regen_headers".

1. http://www.nntp.perl.org/group/perl.perl5.porters/2002/08/msg64603.html
2. http://pauillac.inria.fr/~xleroy/linuxthreads/
3. http://projects.unbit.it/uwsgi/ticket/85

12 years agoMerge branch 'avar/eject-strptime' into blead
Ævar Arnfjörð Bjarmason [Wed, 15 Feb 2012 19:07:34 +0000 (19:07 +0000)]
Merge branch 'avar/eject-strptime' into blead

Ejecting the strptime patches to POSIX out of blead Nicholas Clark
raises some good points about why it shouldn't be in blead as-is, we
can always deal with this in the 5.17 window instead of just before
the user-visible changes freeze.

See the "POSIX-strptime latest code" thread on p5p.

12 years agoPOSIX: bump version to 1.30
Ævar Arnfjörð Bjarmason [Wed, 15 Feb 2012 19:05:13 +0000 (19:05 +0000)]
POSIX: bump version to 1.30

I've reverted the strptime() code, which involved bumping the version
number, bump the version number again to 1.30 so the version number
won't go backwards.

12 years agoRevert "Merge branch 'avar/POSIX-strptime' into blead"
Ævar Arnfjörð Bjarmason [Wed, 15 Feb 2012 18:46:06 +0000 (18:46 +0000)]
Revert "Merge branch 'avar/POSIX-strptime' into blead"

This reverts commit 0e582130ad8fc3afc6514f60b7a513c550379b7d, reversing
changes made to a748fe11f70695552294fe4e31343b2dacb59db2.

Conflicts:

ext/POSIX/POSIX.xs
ext/POSIX/lib/POSIX.pm

12 years agoRevert "Merge branch 'avar/POSIX-strptime' into blead"
Ævar Arnfjörð Bjarmason [Wed, 15 Feb 2012 18:42:15 +0000 (18:42 +0000)]
Revert "Merge branch 'avar/POSIX-strptime' into blead"

This reverts commit 0e582130ad8fc3afc6514f60b7a513c550379b7d, reversing
changes made to 423a1dfc8c367cb58e7dcef73a81b4ec7a8b8810.

12 years agoRevert "Use the strptime() probe in POSIX.xs & tests"
Ævar Arnfjörð Bjarmason [Wed, 15 Feb 2012 18:38:15 +0000 (18:38 +0000)]
Revert "Use the strptime() probe in POSIX.xs & tests"

This reverts commit 05a9a07a5bad262994c7980ced7fffdd93aa2867.

12 years agoRevert "Add strptime probe"
Ævar Arnfjörð Bjarmason [Wed, 15 Feb 2012 18:37:51 +0000 (18:37 +0000)]
Revert "Add strptime probe"

This reverts commit 8852e312c3c616ab731ccbe7da54fb04eb8c3d30.

12 years agoRevert "VMS does have strptime."
Ævar Arnfjörð Bjarmason [Wed, 15 Feb 2012 18:37:33 +0000 (18:37 +0000)]
Revert "VMS does have strptime."

This reverts commit 310f9c6e1d10c69ebae8d0356b22e58f451fdc76.

12 years agoClarify the newSVpvn documentation.
Shlomi Fish [Wed, 15 Feb 2012 11:30:32 +0000 (12:30 +0100)]
Clarify the newSVpvn documentation.

"string" is now called "buffer", and we mention that it might contain NUL
characters.

12 years agoPod::Html's feature2.t needs to match path separators portably.
Nicholas Clark [Tue, 14 Feb 2012 22:06:24 +0000 (23:06 +0100)]
Pod::Html's feature2.t needs to match path separators portably.

On Win32 the path separator in the output it is testing is backslash.
This implies that it will be ] on VMS. Tweak the regular expression to
match these in addition to / for *nix.

12 years agoSkip stat.t readability test on VMS.
Craig A. Berry [Wed, 15 Feb 2012 01:29:07 +0000 (19:29 -0600)]
Skip stat.t readability test on VMS.

This new test grants full access on a test file to group and other.
Since I'm a member of my own group and everyone is someone, I of
course have full access to the file, but the test expects it to be
unreadable.  If there is a hierarchy in Unix file permissions, it
clearly doesn't work the same way as the VMS one.

12 years agoFix Pod::Simple search test for VMS.
Craig A. Berry [Wed, 15 Feb 2012 01:14:54 +0000 (19:14 -0600)]
Fix Pod::Simple search test for VMS.

Awaiting upstream integration at:

https://rt.cpan.org/Public/Bug/Display.html?id=72551

12 years agoFix CGI's url.t test for VMS.
Craig A. Berry [Wed, 15 Feb 2012 01:09:52 +0000 (19:09 -0600)]
Fix CGI's url.t test for VMS.

Awaiting upstream integration at:

https://rt.cpan.org/Public/Bug/Display.html?id=72380

12 years agoperl #110648, single Unicode prop in inverted class not getting inverted
Karl Williamson [Tue, 14 Feb 2012 19:04:21 +0000 (12:04 -0700)]
perl #110648, single Unicode prop in inverted class not getting inverted

Commit b6c46382308166d54090e3d8e385710664693ac0 introduced a bug when
an inverted bracketed character class consists solely of a Unicode
property, that property wasn't getting inverted outside the Latin1
range.

This was due to an optimization that should have been disabled for this
case.

12 years agoSmall updates for perlobj.pod
Dave Rolsky [Tue, 14 Feb 2012 17:05:51 +0000 (11:05 -0600)]
Small updates for perlobj.pod

Fixed some typos.

Improved some wording.

Clarified some points.

12 years agoClarify that @ISA contains scalars which are strings.
Dave Rolsky [Tue, 14 Feb 2012 16:44:02 +0000 (10:44 -0600)]
Clarify that @ISA contains scalars which are strings.

12 years agoDon't reference a specific year for the definition of modern.
Dave Rolsky [Tue, 14 Feb 2012 16:34:41 +0000 (10:34 -0600)]
Don't reference a specific year for the definition of modern.

Just say "with modern Perl" instead of "in 2011".

12 years agoFix a typo (s/lead/led) and some bleah phrasing.
Dave Rolsky [Tue, 14 Feb 2012 16:25:20 +0000 (10:25 -0600)]
Fix a typo (s/lead/led) and some bleah phrasing.

12 years agoUpdate CPANPLUS to CPAN version 0.9118
Chris 'BinGOs' Williams [Tue, 14 Feb 2012 09:47:13 +0000 (09:47 +0000)]
Update CPANPLUS to CPAN version 0.9118

  [DELTA]

  Changes for 0.9118      Mon Feb 13 22:29:33 2012
  ================================================
  * Test reporting enhancements

12 years agoUpdate CPANPLUS-Dist-Build to CPAN version 0.62
Chris 'BinGOs' Williams [Tue, 14 Feb 2012 09:41:51 +0000 (09:41 +0000)]
Update CPANPLUS-Dist-Build to CPAN version 0.62

  [DELTA]

  0.62 Mon Feb 13 22:15:57 GMT 2012
    - Test reporting enhancements

12 years agomixing declarations and assignments not allowed in C89
H.Merijn Brand [Tue, 14 Feb 2012 08:17:02 +0000 (09:17 +0100)]
mixing declarations and assignments not allowed in C89

12 years agoMake pp_study a no-op, as discussed on p5p
Abhijit Menon-Sen [Wed, 1 Feb 2012 05:22:31 +0000 (10:52 +0530)]
Make pp_study a no-op, as discussed on p5p

12 years agois_utf8_char_slow(): Make constistent, correct docs.
Karl Williamson [Mon, 13 Feb 2012 20:13:02 +0000 (13:13 -0700)]
is_utf8_char_slow(): Make constistent, correct docs.

This function is only used by the Perl core for very large code points,
though it is designed to be able to be used for all code points.

For any variant code points, it doesn't succeed unless the passed in
length is exactly the same as the number of bytes the code point
occupies.  The documentation says it succeeds if the length is at least
that number.  This commit updates the documentation to match the
behavior.

Also, for an invariant code point, it succeeds no matter what the
passed-in length says.  This commit changes this to be consistent with
the behavior for all other code points.

12 years agocharnames.t: viacode doesn't return Unicode_1 name always
Karl Williamson [Mon, 13 Feb 2012 18:44:44 +0000 (11:44 -0700)]
charnames.t: viacode doesn't return Unicode_1 name always

There are now four characters which have a different preferred name.

12 years agoavoid unused-var warning from MY_CXT_INIT
Zefram [Mon, 13 Feb 2012 18:14:23 +0000 (18:14 +0000)]
avoid unused-var warning from MY_CXT_INIT

12 years agomktables: viacode() return unparenthesized names for 4 controls
Karl Williamson [Mon, 13 Feb 2012 16:54:22 +0000 (09:54 -0700)]
mktables: viacode() return unparenthesized names for 4 controls

This commit changes the viacode() returned name for four control characters, as
follows:
 Code point      Old Name             New Name
   U+000A    LINE FEED (LF)        LINE FEED
   U+000C    FORM FEED (FF)        FORM FEED
   U+000D    CARRIAGE RETURN (CR)  CARRIAGE RETURN
   U+0085    NEXT LINE (NEL)       NEXT LINE

Only the return from viacode is affected.  All the names are accepted as
input, as they always have been.

Unicode 6.1 now has official names for all the controls, and the new
names match those.  The old names were the ones that were recommended by
TR18 prior to 6.1, and still are, sort of.  This change uses the
official names in preference to the TR18 ones.  We probably wouldn't
bother except that the old names were problematic--the only names in the
whole universe of names containing parentheses, and not matching
traditional usage.  The new names have always been accepted as inputs by
Perl.

I actually doubt that Unicode ever grokked that they were recommending
these ugly names. and they haven't paid much attention to TR18 anyway,
breaking it in version 6.0 by encoding one of the recommended names
(BELL) as an official name for another code point, and without realizing
it.  TR18 now is in limbo, still wrongly recommending BELL, with a
rewrite being promised for many months now.  It's unclear what will
happen with it.

It was agreed on p5p to go with the cleaner, now official names, instead
of the older, likely obsolete, TR18 names.  I did a search of
CPAN; it was unclear if this change, (which again is only for viacode())
mattered to any code there or not.  There were a few instances of the
old names, but none of those were apparently associated with viacode().