This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perl5.git
10 years agoStop using AutoLoader in Storable
David Leadbeater [Tue, 8 Mar 2011 21:45:48 +0000 (21:45 +0000)]
Stop using AutoLoader in Storable

Storable isn't that large by today's standards; using AutoLoader
doesn't make much sense now. Although barely significant this shaves
about 1% off the execution time of the tests on my machine.

10 years agoSwitch Storable to XSLoader from DynaLoader
David Leadbeater [Tue, 8 Mar 2011 21:41:51 +0000 (21:41 +0000)]
Switch Storable to XSLoader from DynaLoader

10 years agoregcomp.c: /a should handle /\xdf/i same as /u
Karl Williamson [Sat, 12 Mar 2011 19:37:40 +0000 (12:37 -0700)]
regcomp.c: /a should handle /\xdf/i same as /u

/a and /u should match identically case-insensitively, but they didn't.
Nor was /a being tested because it was thought that they handled things
identically, and the tests were already taking too long.  So this adds
some tests as well.

10 years agoConvert t/op/study.t to use test.pl, strict and warnings.
Nicholas Clark [Sat, 12 Mar 2011 19:35:00 +0000 (19:35 +0000)]
Convert t/op/study.t to use test.pl, strict and warnings.

Replace its alarm_ok() with test.pl's watchdog().

10 years agoConvert t/op/utf8cache.t to test.pl, strict and warnings.
Nicholas Clark [Sat, 12 Mar 2011 18:11:56 +0000 (18:11 +0000)]
Convert t/op/utf8cache.t to test.pl, strict and warnings.

10 years agoskip_all_without_dynamic_extension() should accepted names containing ::s
Nicholas Clark [Sat, 12 Mar 2011 18:08:24 +0000 (18:08 +0000)]
skip_all_without_dynamic_extension() should accepted names containing ::s

Whilst the package separator is a double colon, config.sh ends up using a /
for the package separator, reflecting how, historically, extensions were
laid out in nested directories beneath ext/. The layout has changed, but the
convention in the config.sh entries, and hence the %Config::Config values,
remains the same.

Hence skip_all_without_dynamic_extension() needs to convert passed-in ::s to
/ before performing a lookup.

10 years agoRename test.pl's skip_all_without_extension to *_dynamic_extension().
Nicholas Clark [Sat, 12 Mar 2011 17:44:59 +0000 (17:44 +0000)]
Rename test.pl's skip_all_without_extension to *_dynamic_extension().

All callers were using it with dynamic extensions, and also had a
skip_all_if_miniperl() for the same extension. Merge the two tests into one
function to save repetition.

10 years agoConvert t/op/readdir.t to test.pl, strict and warnings.
Nicholas Clark [Sat, 12 Mar 2011 17:22:44 +0000 (17:22 +0000)]
Convert t/op/readdir.t to test.pl, strict and warnings.

10 years agoConvert t/op/goto_xs.t to test.pl, strict and warnings.
Nicholas Clark [Sat, 12 Mar 2011 17:06:48 +0000 (17:06 +0000)]
Convert t/op/goto_xs.t to test.pl, strict and warnings.

10 years agoMove pwent.t's test for NIS+ earlier, before the "fallback" of /etc/passwd
Nicholas Clark [Fri, 11 Mar 2011 15:00:31 +0000 (15:00 +0000)]
Move pwent.t's test for NIS+ earlier, before the "fallback" of /etc/passwd

This seems a more logical place for it, on the assumptions that
a: only 1 of the 4 programs tried will produce results
b: Reading from /etc/passwd is intended as a fallback if none produce results.

10 years agoIn t/op/pwent.t, create try_prog() for the common 'try this command' logic.
Nicholas Clark [Fri, 11 Mar 2011 14:52:44 +0000 (14:52 +0000)]
In t/op/pwent.t, create try_prog() for the common 'try this command' logic.

Also refactor the clearing of $reason, without changing the behaviour of when
it is cleared (which is slightly less than logical.)

10 years agoAdd PERL_PRESERVE_IVUV to non_bincompat_options.
Nicholas Clark [Sat, 12 Mar 2011 16:32:08 +0000 (16:32 +0000)]
Add PERL_PRESERVE_IVUV to non_bincompat_options.

It's actually the default, but as all the C code is conditionally (not)
compiled on the basis of that pre-processor macro, seems that it is the one
that needs to be reported.

10 years agoFix RT #84294 /((\w+)(?{print $2})){2,2}/ problem
Yves Orton [Sat, 12 Mar 2011 16:21:54 +0000 (17:21 +0100)]
Fix RT #84294 /((\w+)(?{print $2})){2,2}/ problem

When we are doing a CURLYX/WHILEM loop and the min iterations is
larger than zero we were not saving the buffer state before each
iteration. This mean that partial matches would end up with strange
buffer pointers, with the start *after* the end point.

In more detail WHILEM has four exits, three of which as far as I could
tell would do a regcppush/regcppop in their state transitions, only one,
WHILEM_A_pre which is entered when (n < min) would not. And it is this state
that we repeatedly enter when performing A the min number of times.
When I made the logic similar to the handling of ( n < max ), the bug
went away, and as far as I can tell nothing else broke.

Review by Dave Mitchell required before release.

10 years agoAdd tests for RT #84294 /((\w+)(?{print $2})){2,2}/ problem
Yves Orton [Sat, 12 Mar 2011 16:17:22 +0000 (17:17 +0100)]
Add tests for RT #84294 /((\w+)(?{print $2})){2,2}/ problem

Original ticket reports:

    print "Match: \$1=$1 \$2=$2" if 'ab' =~/^((\w+)(?{print defined $2 ? "\$2=$2\n" : "\$2 not defined\n"})){2}$/;

Produces the following incorrect output:

    $2=ab
    $2 not defined
    $2=b
    Match: $1=b $2=b

It should produce:

    $2=ab
    $2=a
    $2=b
    Match: $1=b $2=b

This adds a TODO test to verify this behavior.

10 years agoIn utf8decode.t, use //x to add comments to the parsing regexp.
Nicholas Clark [Sat, 12 Mar 2011 16:23:32 +0000 (16:23 +0000)]
In utf8decode.t, use //x to add comments to the parsing regexp.

Also, assign directly to variables, instead of going via $1 to $7.

10 years agoIn utf8decode.t, test that we get the expected Unicode character(s)
Nicholas Clark [Sat, 12 Mar 2011 16:02:48 +0000 (16:02 +0000)]
In utf8decode.t, test that we get the expected Unicode character(s)

Previously some (not all) of the "y"es cases detailed the expected code point.
Add all those that were missing, and update the parsing regexp to cope with
multiple Unicode characters.

10 years agoIn utf8decode.t, constrain more tightly the testing of expected warnings.
Nicholas Clark [Sat, 12 Mar 2011 14:32:27 +0000 (14:32 +0000)]
In utf8decode.t, constrain more tightly the testing of expected warnings.

If one warning is expected, use warning_like() to test for it, which will fail
if multiple warnings are generated. Where multiple warnings are generated,
as well as testing that the first seen matches the expected warning, check that
the expected number are seen. Mark as TODO 3.4.1, which Markus Kuhn annotates
as "All the 10 sequences of 3.3 concatenated, you should see 10 malformed
sequences being signalled", because currently perl generates 18 warnings.

10 years agoIn utf8decode.t, use warning_is() for the should-not-warn cases.
Nicholas Clark [Sat, 12 Mar 2011 12:26:06 +0000 (12:26 +0000)]
In utf8decode.t, use warning_is() for the should-not-warn cases.

Move the localised $SIG{__WARN__} handler into the block for the should-warn
case, and avoid using $@ as the warnings accumulator. As an expected warning is
always provided, eliminate the code for dealing with an unspecified expected
warning. The re-ordering allows $id to be a lexical with the same scope as all
others derived from the test table lines.

10 years agoIn utf8decode.t, move the test data from a heredoc to <DATA>
Nicholas Clark [Sat, 12 Mar 2011 12:15:20 +0000 (12:15 +0000)]
In utf8decode.t, move the test data from a heredoc to <DATA>

As the test data is actually somewhat larger than the test code, git's diff
shows this as moving the code upwards :-)
Hence take advantage of the already-churning lines to remove the outermost
block and reindent.

10 years agoIn utf8decode.t, remove the \x sequence strings of bytes
Nicholas Clark [Sat, 12 Mar 2011 12:09:00 +0000 (12:09 +0000)]
In utf8decode.t, remove the \x sequence strings of bytes

For each test case, the information is duplicated in the hex sequences, and
they don't rely on the "" interpolation of the heredoc that initialises the
array @MK

10 years agoIn utf8decode.t, test that the hex sequences and \x escapes are equivalent.
Nicholas Clark [Sat, 12 Mar 2011 11:45:52 +0000 (11:45 +0000)]
In utf8decode.t, test that the hex sequences and \x escapes are equivalent.

The hex sequences had been in the test data since they were first added in
ba210ebec161cde0, but have never actually been used, other than for a length
cross-check.

10 years agoConvert utf8decode.t to test.pl
Nicholas Clark [Sat, 12 Mar 2011 11:41:19 +0000 (11:41 +0000)]
Convert utf8decode.t to test.pl

10 years agoIn test.pl, refactor the implementation of warning_{is,like} and warnings_like.
Nicholas Clark [Sat, 12 Mar 2011 14:09:47 +0000 (15:09 +0100)]
In test.pl, refactor the implementation of warning_{is,like} and warnings_like.

Break out the code to capture warnings from the code to analyse them. Implement
tests directly in warning_{is,like}, rather than implementing them as a call to
warning_like. Remove the C<use warnings "all">, as it is lexically scoped, and
won't apply to the scope of the subroutine being called.

Previously all 3 would erroneously pass if the expectation was for 1 warning,
there were more than 1 warnings, but the first warning matched the expected
warning.

10 years ago11883c88c2a3bf14 introduced an error in 64bitint.t with long doubles.
Nicholas Clark [Sat, 12 Mar 2011 00:03:40 +0000 (00:03 +0000)]
11883c88c2a3bf14 introduced an error in 64bitint.t with long doubles.

On a platform where an NV is long enough to preserve all UVs, division is
always done in floating point. Hence the result may become stringified in E
notation. Hence testing that it is not in E notation (as a testing proxy for
"was integer arithmetic used?") is inappropriate on such a platform.

10 years agoSkip eintr.t on FreeBSD (see perl #85842 and #84688).
Craig A. Berry [Fri, 11 Mar 2011 23:00:46 +0000 (17:00 -0600)]
Skip eintr.t on FreeBSD (see perl #85842 and #84688).

It appears that a larger PerlIO buffer combined with writing to a
pipe triggers an alternate write mechanism in FreeBSD called a
direct write, which is not interruptible by signals.  That's
somewhat speculative and has not been confirmed by someone with
knowledge of FreeBSD internals, but we do know the test hangs, so
it's best not to run it for now.

10 years agoC<not> should be C<!> in utf8decode.t, to fix a precedence bug.
Nicholas Clark [Fri, 11 Mar 2011 23:18:45 +0000 (23:18 +0000)]
C<not> should be C<!> in utf8decode.t, to fix a precedence bug.

Fixing the bug opens a whole can of worms. The test hasn't actually been
testing failure since 35bcd33832d74e56. Indeed, 35bcd33832d74e56 increases
the verbosity of warnings from unpack, meaning that the test needs to aggregate
lines in its $SIG{__WARN__} handler. At which point it passes again.

Until 097fb8e2acde8522, which adds ", immediately" to the UTF-8 diagnostics.
Then 872c91ae155f6880 makes most every form of invalid Unicode warning free,
and also overlong UTF-8 warning free. 618432450ee258c0 makes overlong UTF-8
warn once more. Finally, 08ca2aa38a29585f means that 'U0U*' needs to be
replaced with 'C0U*'.

So now it passes, and (I believe) actually *tests* what it intends to test.
Long may that state of affairs endure.

10 years ago[perl #85884] Erroneous description of File::Basename::fileparse
Father Chrysostomos [Fri, 11 Mar 2011 21:22:43 +0000 (13:22 -0800)]
[perl #85884] Erroneous description of File::Basename::fileparse

Literal backslashes need single quotes.

10 years agoDon't run crashing TODO tests for release builds.
Jan Dubois [Fri, 11 Mar 2011 20:34:39 +0000 (12:34 -0800)]
Don't run crashing TODO tests for release builds.

Crashes on Windows will display an error dialog that has to be
manually dismissed.  This is a bad experience for casual users
not familiar with the practice of TODO tests and might create
doubt in the overall quality of the release.

10 years agoMake sure json_pp is installed on Windows
Jan Dubois [Fri, 11 Mar 2011 18:34:38 +0000 (10:34 -0800)]
Make sure json_pp is installed on Windows

10 years agoAvoid race codition when setting process exit code on Windows.
Jan Dubois [Fri, 11 Mar 2011 18:30:11 +0000 (10:30 -0800)]
Avoid race codition when setting process exit code on Windows.

A Perl program using fork() emulation on Windows may end up
kill()ing the forked child and exiting immediately.  There
is a race condition where the process exit code may be
changed to '9' (the signal used to kill the child thread),
overriding the value the parent thread used in ExitProcess()
(called implicitly with the return value of main()).

Giving up the remainder of the time-slice after terminating
a child thread seems to eliminate this race.

This bug is responsible for various CPAN test failures,
where all tests seem to pass, but Test::Harness still
reports: "Dubious, test returned 9 (wstat 2304, 0x900)"
(e.g. HTTP-Server-Simple, tests based on Test-TCP).

See also https://rt.cpan.org/Ticket/Display.html?id=66016#txn-908976

10 years agoConvert t/op/64bitint.t to test.pl
Nicholas Clark [Fri, 11 Mar 2011 13:58:10 +0000 (13:58 +0000)]
Convert t/op/64bitint.t to test.pl

10 years agoadd more tests for 'my @a =' OPpASSIGN_COMMON
David Mitchell [Fri, 11 Mar 2011 13:36:42 +0000 (13:36 +0000)]
add more tests for 'my @a =' OPpASSIGN_COMMON

bug #70171 was fixed a while ago. This just adds some more tests for the
same (already fixed) bug.

This time its a variant which makes @a already have content at the
'my @a =' declaration, but without requiring a closure.
 See also [perl #82110].

10 years agoRefactor die_exit.t to loop over a list, rather than iterate on an hash.
Nicholas Clark [Fri, 11 Mar 2011 11:37:07 +0000 (11:37 +0000)]
Refactor die_exit.t to loop over a list, rather than iterate on an hash.

10 years agoConvert t/op/die_exit.t to test.pl
Nicholas Clark [Fri, 11 Mar 2011 11:29:23 +0000 (11:29 +0000)]
Convert t/op/die_exit.t to test.pl

10 years agoregexec.c: Use equivalent macro instead of code
Karl Williamson [Fri, 11 Mar 2011 02:52:55 +0000 (19:52 -0700)]
regexec.c: Use equivalent macro instead of code

Recent simplification of this code left it to be the equivalent
of an existing macro

10 years agoCorrect the U<...> link in perlfaq4
Father Chrysostomos [Fri, 11 Mar 2011 00:47:04 +0000 (16:47 -0800)]
Correct the U<...> link in perlfaq4

10 years agoMerge branch 'blead' of ssh://perl5.git.perl.org/gitroot/perl into blead
Father Chrysostomos [Fri, 11 Mar 2011 00:41:39 +0000 (16:41 -0800)]
Merge branch 'blead' of ssh://perl5.git.perl.org/gitroot/perl into blead

10 years agoThe "Send a CC" checkbox on PAUSE is gone
Florian Ragwitz [Fri, 11 Mar 2011 00:23:28 +0000 (01:23 +0100)]
The "Send a CC" checkbox on PAUSE is gone

Update the release-manager's guide accordingly.

10 years agoUpdate link to "What Every Computer Scientist Should Know About Floating-Point Arithm...
brian d foy [Thu, 10 Mar 2011 22:50:45 +0000 (16:50 -0600)]
Update link to "What Every Computer Scientist Should Know About Floating-Point Arithmetic"

10 years agoregexec.c: Add assert() to detect inconsistent ANYOF
Karl Williamson [Thu, 10 Mar 2011 15:22:00 +0000 (08:22 -0700)]
regexec.c: Add assert() to detect inconsistent ANYOF

There have been various segfaults apparently due to trying to access
the swash (and allies) portion of an ANYOF which doesn't have that.
This doesn't show up on all platforms.  The assert() should detect
this and help debugging

10 years agoregexec.c: Fix precedence
Karl Williamson [Thu, 10 Mar 2011 15:17:05 +0000 (08:17 -0700)]
regexec.c: Fix precedence

Commit ac51e94be5daabecdeb0ed734f3ccc059b7b77e3 didn't
do what it purported, because it omitted parentheses that
were necessary to change the natural precedence.  It's strange that
it passed all tests on my machine, and failed so miserably elsewhere
that it was quickly reverted by commit
63c0bfd59562325fed2ac5a90088ed40960ac2ad.

This reinstates it with the correct precedence.  The next commit
will add an assert() so that the underlying issue will be detected
on all platforms

10 years agoregcomp.c: call regclass_swash() only if non-empty
Karl Williamson [Thu, 10 Mar 2011 15:58:34 +0000 (08:58 -0700)]
regcomp.c: call regclass_swash() only if non-empty

We can tell if there is something outside the bitmap and so
can short circuit calling this function if there isn't.

10 years agoRevert "regexec.c: don't try accessing non-bitmap if doesn't exist"
David Mitchell [Thu, 10 Mar 2011 14:42:20 +0000 (14:42 +0000)]
Revert "regexec.c: don't try accessing non-bitmap if doesn't exist"

This reverts commit ac51e94be5daabecdeb0ed734f3ccc059b7b77e3.

This commit made many of the re/*.t tests fail, on my build at least.
Haven't looked at why, just reverting it for the moment.

10 years agoCPAN is upstream for Scalar-List-Utils
Florian Ragwitz [Thu, 10 Mar 2011 13:53:25 +0000 (14:53 +0100)]
CPAN is upstream for Scalar-List-Utils

As confirmed by Graham.

10 years agoregexec.c: don't try accessing non-bitmap if doesn't exist
Karl Williamson [Thu, 10 Mar 2011 04:28:35 +0000 (21:28 -0700)]
regexec.c: don't try accessing non-bitmap if doesn't exist

ANYOF_NONBITMAP is supposed to be set iff there is something outside
the bitmap to try matching in an ANYOF node.  Due to slight changes in
the meaning of this, the code has been trying to access this
if ANYOF_NONBITMAP_NON_UTF8 is set without ANYOF_NONBITMAP being set,
which means it was trying to access something that doesn't exist.

I'm hopeful, based on a stack trace sent to me  that this is the cause
of [perl #85478], but can't reproduce that easily.  But the logic
is clearly wrong.

10 years agoinstallperl: Don't install unnecessary unicore/*.txt
Karl Williamson [Thu, 10 Mar 2011 02:08:48 +0000 (19:08 -0700)]
installperl: Don't install unnecessary unicore/*.txt

This removes from installation certain .txt files in unicore that
are no longer needed for execution by Unicode::UCD, since commit
05dbc6f80f8f2d5774f53874803f5a20450bbe82

10 years agoperlfunc/pos: Mention the zero-len flag
Father Chrysostomos [Thu, 10 Mar 2011 01:47:33 +0000 (17:47 -0800)]
perlfunc/pos: Mention the zero-len flag

10 years agoperlre clean-up
Father Chrysostomos [Wed, 9 Mar 2011 20:58:03 +0000 (12:58 -0800)]
perlre clean-up

Mostly typos, grammatical errors and factual errors (mostly due to
bitrot), but also:

• The section explaining how to work around the lack of look behind
  obviously has not been relevant for years. :-)
• Since we have relative backreferences, we might as well use them in
  the explanation of the (?>...) construct.
• Note that it’s possible to backtrack *past* (?>...), but
  not into it.
• (?:non-zero-length|zero-length)* is *not* equivalent to nzl*|zl? as
 "aaaaab" =~ /(?:a|(?{print "hello"})(?=(b)))*/ demonstrates.
• The custom re engine section doesn’t mention custom re engines. :-)

10 years agoperldelta for 9407f9c1
David Leadbeater [Wed, 9 Mar 2011 20:48:54 +0000 (20:48 +0000)]
perldelta for 9407f9c1

10 years agoHave git-deltatool list the commit's author
Florian Ragwitz [Wed, 9 Mar 2011 20:53:56 +0000 (21:53 +0100)]
Have git-deltatool list the commit's author

Some authors are more likely to include delta entries in their commits than
others. Knowing who wrote a commit at a glance when reviewing it is helpful.

10 years ago[perl #85738] cc deprecated option warnings on solaris 10 sparc 64-bit
Arvan [Wed, 9 Mar 2011 19:35:48 +0000 (11:35 -0800)]
[perl #85738] cc deprecated option warnings on solaris 10 sparc 64-bit

When building on Solaris 10 multiple warnings are produced saying:

Warning: -xarch=generic64 is deprecated, use -m64 to create 64-bit
programs

This is because the config script hints/solaris_2.sh uses the values
returned by getconf which are incorrect for newer versions of Sun's
compiler. I believe they are correct for earlier versions, but do not
have a system to test this on. This change to solaris_2.sh checks
that the compiler produces this warning, and if so updates the flags
to the correct values.

10 years agoAdd Arvan to AUTHORS
Father Chrysostomos [Wed, 9 Mar 2011 19:34:04 +0000 (11:34 -0800)]
Add Arvan to AUTHORS

10 years agoA couple of perldelta updates
Florian Ragwitz [Wed, 9 Mar 2011 20:17:08 +0000 (21:17 +0100)]
A couple of perldelta updates

It's still far from being complete :-/

10 years agoUpdate Digest-SHA to CPAN version 5.61
Chris 'BinGOs' Williams [Wed, 9 Mar 2011 14:45:15 +0000 (14:45 +0000)]
Update Digest-SHA to CPAN version 5.61

5.61  Wed Mar  9 05:26:36 MST 2011
        - corrected bug in 'algorithm' method
        - fixed -x option in Makefile.PL
                -- not often used since it deliberately excludes
                        all 64-bit SHA transforms
        - addressed minor documentation oversights

10 years agoRemove DECCRTL_SOCKETS from PL_bincompat_options.
Craig A. Berry [Wed, 9 Mar 2011 13:14:41 +0000 (07:14 -0600)]
Remove DECCRTL_SOCKETS from PL_bincompat_options.

The socket libraries provided by the C run-time have been the
only viable option for building sockets in Perl for many years,
so we don't need to take up a valuable slot in the options list
to record that we're using them.

Also, the new bincompat.t test requires options to be in alpha-
betical order, and this wasn't.

10 years agoIn fold_grind.t only report OK for each charset/target combination
David Leadbeater [Wed, 9 Mar 2011 00:48:24 +0000 (16:48 -0800)]
In fold_grind.t only report OK for each charset/target combination

This brings the number of tests down significantly and due to the
reduced amount of printing the runtime too. Failing tests are still
reported and a complete run can be enabled by setting
$ENV{PERL_DEBUG_FULL_TEST} to a true value.

10 years agoregcomp.c: Rmv unused parameter
Karl Williamson [Wed, 9 Mar 2011 06:19:16 +0000 (23:19 -0700)]
regcomp.c: Rmv unused parameter

This silences a compiler warning

10 years agore/pat.t: Remove TODO message on passing tests
Karl Williamson [Wed, 9 Mar 2011 06:14:45 +0000 (23:14 -0700)]
re/pat.t: Remove TODO message on passing tests

A previous commit fixed these.

10 years agoregcomp.c: Rmv unused parameter
Karl Williamson [Wed, 9 Mar 2011 06:13:59 +0000 (23:13 -0700)]
regcomp.c: Rmv unused parameter

This silences a compiler warning

10 years agoregcomp.c: Rmv unused parameter
Karl Williamson [Wed, 9 Mar 2011 06:08:16 +0000 (23:08 -0700)]
regcomp.c: Rmv unused parameter

This silences a compiler warning

10 years agoPATCH: [perl #85528], add initialization
Karl Williamson [Wed, 9 Mar 2011 05:56:02 +0000 (22:56 -0700)]
PATCH: [perl #85528], add initialization

Commit 137165a601b852a9679983cdfe8d35be29f0939c omitted
required initialization for the synthetic start class.  Adding it
exposed other bugs in cl_and() and cl_or(), which have been fixed
by a previous commit.

10 years agoregcomp.c: revamp cl_and() and cl_or()
Karl Williamson [Wed, 9 Mar 2011 05:35:36 +0000 (22:35 -0700)]
regcomp.c: revamp cl_and() and cl_or()

These two routines have not kept pace with the changes in the ANYOF
flags.  And, I believe there were issues even before them.  I did a
systematic re-thinking of what their behaviors should be.

10 years agoregcomp.h: #define of ANYOF flags immune from inversion
Karl Williamson [Wed, 9 Mar 2011 04:57:24 +0000 (21:57 -0700)]
regcomp.h: #define of ANYOF flags immune from inversion

10 years agoregex: /l in combo with others in syn start class
Karl Williamson [Wed, 9 Mar 2011 00:06:47 +0000 (17:06 -0700)]
regex: /l in combo with others in syn start class

Now that regexes can be combinations of different charset modifiers,
a synthetic start class can match locale and non-locale both.  locale
should generally match only things in the bitmap for code points < 256.
But a synthetic start class with a non-locale component can match such
code points.  This patch makes an exception for synthetic nodes that
will be resolved if it passes and is matched again for real.

10 years agoregcomp.c: UTF /l should not use tries
Karl Williamson [Tue, 8 Mar 2011 23:30:00 +0000 (16:30 -0700)]
regcomp.c: UTF /l should not use tries

It's unclear if tries will work under /l.  I haven't seen any failures,
but there have been under /d.  As a precaution, until more testing is
done, disable tries under anything but /u and UTF.

10 years agoregcomp.c: Merge identical functions
Karl Williamson [Tue, 8 Mar 2011 23:20:52 +0000 (16:20 -0700)]
regcomp.c: Merge identical functions

These two functions now have identical code, so merge them, but use
a macro in case they ever need to diverge again.

10 years agoregcomp.c: Change start class init for /l
Karl Williamson [Tue, 8 Mar 2011 22:28:05 +0000 (15:28 -0700)]
regcomp.c: Change start class init for /l

Before /l was added, locale only applied to regular expressions as a
whole.  Now it can be subsections, so the flag for allowing it
should be treated as any other flag.

10 years agoregcomp.c: clarify comments
Karl Williamson [Tue, 8 Mar 2011 22:25:27 +0000 (15:25 -0700)]
regcomp.c: clarify comments

10 years agoregcomp.c: Move #defines to be be in bit order
Karl Williamson [Sun, 6 Mar 2011 16:00:52 +0000 (09:00 -0700)]
regcomp.c: Move #defines to be be in bit order

10 years agofix C++ build error introducted in f8088870
Tony Cook [Wed, 9 Mar 2011 03:44:25 +0000 (14:44 +1100)]
fix C++ build error introducted in f8088870

10 years agotaint.t broken by refactoring
Craig A. Berry [Wed, 9 Mar 2011 03:31:54 +0000 (21:31 -0600)]
taint.t broken by refactoring

Somewhere in the fifteen! commits to taint.t in the last couple of
weeks, the truth got lost.  Literally.  Instead of testing for
falsehood, we were testing for equivalence to empty string. What
we actually get is undef, so test for that.

10 years agoAdd PERL_NO_GET_CONTEXT to NamedCapture.xs
Nicholas Clark [Tue, 8 Mar 2011 20:14:11 +0000 (20:14 +0000)]
Add PERL_NO_GET_CONTEXT to NamedCapture.xs

10 years agoTweak Tie::Hash::NamedCapture's BOOT code - get the stash from the CV.
Nicholas Clark [Tue, 8 Mar 2011 20:01:46 +0000 (20:01 +0000)]
Tweak Tie::Hash::NamedCapture's BOOT code - get the stash from the CV.

This will result in less work than using newSVrv(), as the character string
passed to that is used to walk the symbol table to find the stash. We already
have a fast way to get to the stash - via the CV's GV. So use that directly.

10 years agoUpdate parent to CPAN version 0.225
Chris 'BinGOs' Williams [Tue, 8 Mar 2011 21:27:37 +0000 (21:27 +0000)]
Update parent to CPAN version 0.225

  [DELTA]

  0.225  20110308
    . Applied a docpatch by Robin Barker to fix the documentation
      about the warning of inheriting from yourself.
      Fixes RT #66459

10 years agoMention when reflags was added
Father Chrysostomos [Tue, 8 Mar 2011 20:01:44 +0000 (12:01 -0800)]
Mention when reflags was added

10 years agoAnother typo in perlretut
Father Chrysostomos [Tue, 8 Mar 2011 06:53:18 +0000 (22:53 -0800)]
Another typo in perlretut

10 years agomention reflags in perlretut
Father Chrysostomos [Tue, 8 Mar 2011 06:49:03 +0000 (22:49 -0800)]
mention reflags in perlretut

10 years agoEven more perlretut tweaks
Father Chrysostomos [Tue, 8 Mar 2011 06:45:35 +0000 (22:45 -0800)]
Even more perlretut tweaks

10 years agoIn reg_namedcapture.t, don't test for Errno, as the miniperl skip covers this.
Nicholas Clark [Tue, 8 Mar 2011 18:43:41 +0000 (18:43 +0000)]
In reg_namedcapture.t, don't test for Errno, as the miniperl skip covers this.

The original reason for adding the test for Errno was because of a report of
tests failing under minitest:
http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-03/msg00467.html

10 years agoIn Tie::Hash::NamedCapture move the tie of %+ and %- from perl to XS.
Nicholas Clark [Tue, 8 Mar 2011 17:33:39 +0000 (17:33 +0000)]
In Tie::Hash::NamedCapture move the tie of %+ and %- from perl to XS.

10 years agoConvert Tie::Hash::NamedCapture::TIEHASH to XS.
Nicholas Clark [Tue, 8 Mar 2011 16:46:36 +0000 (16:46 +0000)]
Convert Tie::Hash::NamedCapture::TIEHASH to XS.

10 years agoAdd tests for documented behaviour of Tie::Hash::NamedCapture::TIEHASH.
Nicholas Clark [Tue, 8 Mar 2011 15:28:37 +0000 (15:28 +0000)]
Add tests for documented behaviour of Tie::Hash::NamedCapture::TIEHASH.

10 years agoUpdate JSON-PP to CPAN version 2.27105
Chris 'BinGOs' Williams [Tue, 8 Mar 2011 15:22:03 +0000 (15:22 +0000)]
Update JSON-PP to CPAN version 2.27105

  [DELTA]

  2.27105  Tue Mar  8 12:38:42 2011
    - removed t/900_pod.t from package because of author test

Merely a version bump

10 years agoCheck for threads before multiplicity in configure.com.
Craig A. Berry [Tue, 8 Mar 2011 13:23:49 +0000 (07:23 -0600)]
Check for threads before multiplicity in configure.com.

3b28d668e9efe9433c3099521167a6723cbddc26 depended on command-line
specification of usethreads, which of course may not be there.

10 years agoIn test.pl, use block eval instead of string eval for requiring modules.
Nicholas Clark [Tue, 8 Mar 2011 11:25:34 +0000 (11:25 +0000)]
In test.pl, use block eval instead of string eval for requiring modules.

The failure we're protecting against is runtime, rather than compile time.

10 years agoRefactor skip_all_without_config() to take a list of config options to test.
Nicholas Clark [Tue, 8 Mar 2011 10:46:14 +0000 (10:46 +0000)]
Refactor skip_all_without_config() to take a list of config options to test.

Previously it took a second argument as a reason to show in the skip_all
message, if the config option was not set. However, no callers were using it,
so remove it. This allows skip_all_without_config() to take a list of keys
to test, which is useful to two of its callers.

10 years agoSimplify the logic in t/thread_it.pl, as the callers' filenames are uniform.
Nicholas Clark [Tue, 8 Mar 2011 10:31:32 +0000 (10:31 +0000)]
Simplify the logic in t/thread_it.pl, as the callers' filenames are uniform.

VMS invokes TEST with Unix-style filenames, so using / as a separator inside
t/thread_it.pl should not pose a portability problem. ':' is irrelevant now
that MacOS Classic is very "special biologist word".

10 years ago4f890a3067e1198f missed qr// from t/re/pat.t in its refactoring in two places.
Nicholas Clark [Tue, 8 Mar 2011 09:56:48 +0000 (09:56 +0000)]
4f890a3067e1198f missed qr// from t/re/pat.t in its refactoring in two places.

like($@, /A pattern/, "Description") is going to compare $@ with the
*result* of matching $_ against that pattern, not that pattern.

10 years agoNothing uses $ENV{PERL_CORE_MINITEST} any more, so don't set it in t/TEST
Nicholas Clark [Tue, 8 Mar 2011 09:33:21 +0000 (09:33 +0000)]
Nothing uses $ENV{PERL_CORE_MINITEST} any more, so don't set it in t/TEST

10 years agoMove the special-case logic for $qr_embed_thr to regexp_qr_embed_thr.t
Nicholas Clark [Tue, 8 Mar 2011 09:02:31 +0000 (09:02 +0000)]
Move the special-case logic for $qr_embed_thr to regexp_qr_embed_thr.t

t/re/regexp_qr_embed_thr.t is the only place that sets $::qr_embed_thr, so move
the special-case startup logic related to it from t/re/regexp.t to
t/re/regexp_qr_embed_thr.t. Use the skip_all_*() functions from test.pl

10 years agoRefactor inccode.t to use is_miniperl() instead of $ENV{PERL_CORE_MINITEST}
Nicholas Clark [Tue, 8 Mar 2011 08:59:54 +0000 (08:59 +0000)]
Refactor inccode.t to use is_miniperl() instead of $ENV{PERL_CORE_MINITEST}

10 years agoUpdate Module::Build to CPAN version 0.3800
David Golden [Tue, 8 Mar 2011 02:24:15 +0000 (21:24 -0500)]
Update Module::Build to CPAN version 0.3800

[DELTA]

0.3800 - Sat Mar  5 15:11:41 EST 2011

  Summary of major changes since 0.3624:

    [ENHANCEMENTS]

    - Generates META.json and MYMETA.json consistent with version 2 of the
      CPAN Meta Spec. [David Golden]

  Also in this release:

  [BUG FIXES]

  - Autogenerated documentation no longer includes private actions from
    Module::Build's own release subclass. [Report by Timothy Appnel,
    fix by David Golden]

0.37_06 - Mon Feb 28 21:43:31 EST 2011

  [BUG FIXES]

  - prerequisites with the empty string instead of a version are
    normalized to "0".  (RT#65909)

  [OTHER]

  - More Pod typo/link fixes [Hongwen Qiu]

10 years ago[perl #85638] Docs for 'inherit from yourself' warning in base.pm
Robin Barker [Tue, 8 Mar 2011 00:36:39 +0000 (16:36 -0800)]
[perl #85638] Docs for 'inherit from yourself' warning in base.pm

The "inherit from yourself" is triggered by
C<package Foo; use base 'Foo';> not C<use Foo; use base 'Foo';>
as stated in the documentation.

10 years agoIncrease base.pm’s version
Father Chrysostomos [Tue, 8 Mar 2011 00:35:28 +0000 (16:35 -0800)]
Increase base.pm’s version

10 years agoIncrease Math::BigInt’s version
Father Chrysostomos [Tue, 8 Mar 2011 00:31:51 +0000 (16:31 -0800)]
Increase Math::BigInt’s version

There is a 1.993 release on CPAN. There have been more changes since.

10 years agoSet multiplicity in configure.com when usethreads is enabled.
Craig A. Berry [Tue, 8 Mar 2011 00:52:33 +0000 (18:52 -0600)]
Set multiplicity in configure.com when usethreads is enabled.

It's hard-wired in perl.h, so it doesn't make any difference to
what's seen by the C code, but $Config{multiplicity} should reflect
what we're actually doing (and track what Configure does).

10 years agoMove the test for 078c425b721ea35d from fresh_perl.t to pat_rt_report.t
Nicholas Clark [Mon, 7 Mar 2011 22:08:05 +0000 (22:08 +0000)]
Move the test for 078c425b721ea35d from fresh_perl.t to pat_rt_report.t

It happens to be the only test in fresh_perl.t that skips on miniperl.
pat_rt_report.t automatically skips on miniperl, and isn't exclusively for
bugs reported via RT.

10 years agoRefactor 4 tests to use skip_if_miniperl().
Nicholas Clark [Mon, 7 Mar 2011 21:55:36 +0000 (21:55 +0000)]
Refactor 4 tests to use skip_if_miniperl().

10 years agoRefactor sigdispatch.t to use is_miniperl() instead testing %ENV for minitest.
Nicholas Clark [Mon, 7 Mar 2011 21:54:40 +0000 (21:54 +0000)]
Refactor sigdispatch.t to use is_miniperl() instead testing %ENV for minitest.

10 years agoRefactor t/thread_it.pl to use test.pl's skip_all_*() functions.
Nicholas Clark [Mon, 7 Mar 2011 21:03:20 +0000 (21:03 +0000)]
Refactor t/thread_it.pl to use test.pl's skip_all_*() functions.