This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Karl Williamson [Fri, 24 Aug 2018 18:34:18 +0000 (12:34 -0600)]
t/re/regexp_unicode_prop.t: Add tests
Add some tests. These test various error conditions that haven't been
tested before.
Karl Williamson [Wed, 15 Aug 2018 23:11:15 +0000 (17:11 -0600)]
t/re/regexp_unicode_prop.t: Test that can have nested pkgs
That is, in \p{user-defined}
Karl Williamson [Wed, 15 Aug 2018 23:09:45 +0000 (17:09 -0600)]
t/re/regexp_unicode_prop.t: Add some stress
This adds some trailing spaces and comments in expansion of
\p{user-defined}/ to verify things work.
Karl Williamson [Wed, 15 Aug 2018 23:07:51 +0000 (17:07 -0600)]
t/op/taint.t: Add test
Karl Williamson [Thu, 23 Aug 2018 20:05:29 +0000 (14:05 -0600)]
regcomp.c: Add some potential code that's #ifdef'd out
This is in case we ever need it. This checks for portability in the
code points specified in user-defined properties. Previously there was
a check, but I couldn't get a warning to trigger unless there was also
overflow. So that means the pattern compile failed due to the overflow,
and the portability warning was superfluous. But, one can have
non-portable code points without overflow; just the old method didn't
properly detect them. If we do ever need to detect and report on them,
the code is mostly written and in this commit.
Karl Williamson [Tue, 21 Aug 2018 00:31:04 +0000 (18:31 -0600)]
Move \p{user-defined} to core from utf8_heavy.pl
This large commit moves the handling of user-defined properties to C
code. This should speed it up, but the main reason to do this is to
stop using swashes in this case, leaving only tr/// using them. Once
that too is converted, all swash handling can be ripped out of perl.
Doing this in perl has caused some nasty interactions that will now be
fixed automatically.
The change is not entirely transparent, however (besides speed and the
possibility of removing these interactions). perldelta in this commit
details these.
Karl Williamson [Wed, 15 Aug 2018 22:11:04 +0000 (16:11 -0600)]
Add global hash to handle \p{user-defined}
A global hash has to be specially handled. The keys can't be shared,
and all the SVs stored into it must be in its thread. This commit adds
the hash, and initialization, and macros for context change, but doesn't
use them. The code to deal with this is entirely confined to regcomp.c.
Karl Williamson [Wed, 15 Aug 2018 21:45:14 +0000 (15:45 -0600)]
Add mutex for dealing with qr/\p{user-defined}/
This will be used in future commits
Karl Williamson [Mon, 6 Aug 2018 23:39:35 +0000 (17:39 -0600)]
regcomp.c: Add/reword some comments/white-space
Karl Williamson [Fri, 3 Aug 2018 20:12:49 +0000 (14:12 -0600)]
regcomp.c: Change variable name
The new name more closely corresponds with its use.
Nicolas R [Thu, 14 Feb 2019 21:44:24 +0000 (14:44 -0700)]
perldelta prep setup for v5.29.8
This is a preparation commit for the future
Perl v5.29.8 release.
perldelta still contains some placeholder which
would need to be cleanup before release and would
also need to take into account any changes since
commit
5eabe055
Several sections have already been removed considering
they would not be used, feel free to restore them if required.
Nicolas R [Thu, 14 Feb 2019 19:12:41 +0000 (13:12 -0600)]
perldelta module changes from ext,lib
remove useless module sections for 5.29.8
Nicolas R [Thu, 14 Feb 2019 18:45:20 +0000 (12:45 -0600)]
Update Modules section for perldelta for 5.29.8
List cpan & dist packages updated since v5.29.7
and add a warning for the JSON::PP incompatible changes.
Nicolas R [Thu, 14 Feb 2019 16:30:34 +0000 (10:30 -0600)]
Update JSON-PP to CPAN version 4.00
[DELTA]
4.00 2018-12-07
- production release
3.99_01 2018-12-03
- BACKWARD INCOMPATIBILITY:
As JSON::XS 4.0 changed its policy and enabled allow_nonref
by default, JSON::PP also enabled allow_nonref by default
- implement allow_tags that was introduced by JSON::XS 3.0
- add boolean_values that was introduced by JSON::XS 4.0
- allow literal tags in strings in relaxed mode, as JSON::XS 3.02 does
- allow PERL_JSON_PP_USE_B environmental variable to restore
old number detection behavior for compatibility
- various doc updates
Nicolas R [Thu, 14 Feb 2019 16:15:10 +0000 (10:15 -0600)]
t/porting/manifest.t add line number
Improve t/porting/manifest.t output on errors
to show the line number.
Nicolas R [Thu, 14 Feb 2019 02:22:10 +0000 (20:22 -0600)]
Net::Ping 501_ping_icmpv6.t: disable sudo test
This is similar to the changes made in
7bfdd8260c
we do not want to use 'sudo' during the tests.
Nicolas R [Thu, 14 Feb 2019 00:32:46 +0000 (18:32 -0600)]
Update Net::Ping to upstream version 2.71
This retains blead customizations:
*
1a58b39af8 remove of 'use vars'
*
7bfdd8260c 500_ping_icmp.t: remove sudo code
These changes are not required anymore, they
are merged upstream
*
0fc44d0a18 avoid stderr noise in tests
Chris 'BinGOs' Williams [Thu, 14 Feb 2019 13:17:57 +0000 (13:17 +0000)]
Update Test-Simple to CPAN version 1.302162
[DELTA]
1.302162 2019-02-05 19:55:14-08:00 America/Los_Angeles
- Typo fixes in documentation
Nicolas R [Wed, 13 Feb 2019 23:58:31 +0000 (17:58 -0600)]
Update Module-Load to CPAN version 0.34
[DELTA]
0.34 Sun Feb 10 13:56:54 GMT 2019
* Added SEE ALSO section to documentation. RT#100575
* Unreachable code cleanup (https://github.com/jib/cpanplus-devel/pull/15)
Karl Williamson [Wed, 13 Feb 2019 17:02:13 +0000 (10:02 -0700)]
perlrecharclass: Note many fewer xdigits than digts
This adds a note explaining why there are only two sets of hex digits
Karl Williamson [Wed, 13 Feb 2019 16:33:56 +0000 (09:33 -0700)]
perlrecharclass: Rmv obsolete RFC
The deleted text asked for comments on a proposal that never went
anywhere.
Karl Williamson [Wed, 13 Feb 2019 16:30:29 +0000 (09:30 -0700)]
perlrecharclass: Clarify
See http://blogs.perl.org/users/tom_wyant/2019/01/untrusted-numeric-input.html
Tony Cook [Wed, 6 Feb 2019 04:42:10 +0000 (15:42 +1100)]
(perl #133660) add test for goto &sub in overload leaking
The bug in this case was fixed in
db9848c8d.
Andreas Koenig [Sun, 10 Feb 2019 16:20:57 +0000 (16:20 +0000)]
perlsyn.pod: correct typo in doc
Karl Williamson [Wed, 6 Feb 2019 18:54:14 +0000 (11:54 -0700)]
makedef.pl: Fix to work with -DNO_LOCALE config opt
We shouldn't export non-existent variables
Karl Williamson [Wed, 6 Feb 2019 18:53:10 +0000 (11:53 -0700)]
locale.c: Fix compilation error
This code would fail to require if Configure had ccflags=-DNO_LOCALE
Karl Williamson [Wed, 6 Feb 2019 18:51:05 +0000 (11:51 -0700)]
t/loc_tools.pl: C.UTF-8 is a likely locale
When looking for locales on a system, try this one which seems to be
getting to be available widely.
Karl Williamson [Wed, 6 Feb 2019 18:49:25 +0000 (11:49 -0700)]
ext/POSIX: Fix compilation error
This code is not usually compiled, but if tried, it would fail. It
needed a cast.
Karl Williamson [Tue, 5 Feb 2019 18:45:10 +0000 (11:45 -0700)]
Merge branch 'turkic locale handling' into blead
This series of commmits adds seamdless handling of UTF-8 Turkic locales
to blead. Unicode furnishes an alternate set of casing rules for these
locales, which until now were ignored by Perl. These commits causes
Perl to use the alternate rules when it detects that the UTF-8 locale it
is using is in fact a specialized Turkic one
Karl Williamson [Tue, 5 Feb 2019 18:30:05 +0000 (11:30 -0700)]
Docs for new Turkic UTF-8 locale support
Karl Williamson [Tue, 5 Feb 2019 01:58:26 +0000 (18:58 -0700)]
locale.c: Add detection of Turkic UTF-8 locales
When switching into a new locale, after it is decided this is a UTF-8
locale, the code now also checks for if the locale is a specialized
Turkic one, which has a couple of slightly modified casing change rules.
If so, it sets a flag indicating this.
The code that has been added in previous commits in this series check if
that flag is set when they are actually paying attention to the
background locale, and if so behave according to Unicode Turkic rules.
Karl Williamson [Tue, 5 Feb 2019 01:30:25 +0000 (18:30 -0700)]
regcomp.c: White-space only
Indent a block of code newly formed by the previous commit
Karl Williamson [Tue, 5 Feb 2019 00:46:20 +0000 (17:46 -0700)]
Add Turkish locale handling to /i pattern matching
Previous commits in this series have changed uc(), lc(), fc(), etc. to
know how to handle Turkish UTF-8 locales. This commit extends this to
/i regular expression pattern matching.
Karl Williamson [Mon, 4 Feb 2019 23:18:51 +0000 (16:18 -0700)]
pp.c: White-space only
Indent block newly formed by the previous commit.
Karl Williamson [Mon, 4 Feb 2019 23:12:58 +0000 (16:12 -0700)]
pp.c: Add handling for Turkish locales for uc() etc
The functions lc() uc() ucfirst() lcfirst() and fc() are hereby expanded
to handle the differences required in Turkish locales.
No Turkish locales are recognized until later in this series of
commits.
Karl Williamson [Mon, 4 Feb 2019 23:03:49 +0000 (16:03 -0700)]
t/op/lc.t: Add tests for Turkish locales
But since these aren't recognized yet, they will be skipped
Karl Williamson [Mon, 4 Feb 2019 22:29:55 +0000 (15:29 -0700)]
Add .t to test Turkic locale folding
This just calls fold_grind.pl with a particular option.
But, as of this commit, Turkish locales aren't recognized specially, so
this test just always skips.
Karl Williamson [Mon, 4 Feb 2019 22:23:31 +0000 (15:23 -0700)]
t/re/fold_grind.pl: Enhance to deal with Turkic rules
The CaseFolding.txt file has special locale-dependent rules. This
commit changed fold_grind to notice them, and to generate tests for
the situation we aren't in, which are expected to fail.
Since, as of this commit, the Turkic locale is not recognized, this
commit has the effect of generating tests for the Turkic locale, running
them, and making sure they fail when appropriate.
Karl Williamson [Mon, 4 Feb 2019 21:18:18 +0000 (14:18 -0700)]
t/loc_tools.pl: Add functions to find Turkic UTF-8 locales
These will be used by later commits. But right now Perl doesn't know
how to determine if a locale is Turkic, so these functions return no
locale, until later in this commit series
Karl Williamson [Mon, 4 Feb 2019 21:07:11 +0000 (14:07 -0700)]
utf8.c: Add functions for Turkic locale case changing
These override the normal handling of UTF-8 locale case changing.
They aren't actually called yet, until later in this series of commits.
Karl Williamson [Mon, 4 Feb 2019 21:11:08 +0000 (14:11 -0700)]
Add variable for if the current UTF-8 locale is Turkic
It currently is always set false, until later in this series of commits.
Karl Williamson [Mon, 4 Feb 2019 16:18:24 +0000 (09:18 -0700)]
regcomp.c: Under /l any < 256 char can match any other
The code knew this, but it was adding the ASCII alphabetics to the list
of things that matched in UTF-8 locales. This is unnecessary, as we've
long had the infrastructure elsewhere to handle all potential mappings
from a Latin1 code point to other Latin1, so we can just rely on it.
And it created complexities for future commits in this series.
The MICRO SIGN is the exception, as it folds to non-Latin1 in UTF-8
locales, and this is the place where the structure exists to handle
that.
Karl Williamson [Sun, 3 Feb 2019 17:03:18 +0000 (10:03 -0700)]
regen/regcharclass.pl: Remove obsolete macro
This has been replaced by regen/unicode_constants.pl some releases ago.
Karl Williamson [Fri, 1 Feb 2019 18:22:15 +0000 (11:22 -0700)]
regen/mk_invlists.pl: Create new inversion list
This will be used in a future commit.
Karl Williamson [Mon, 21 Jan 2019 16:46:00 +0000 (09:46 -0700)]
mktables: Make Turkic 'I' chars problematic
In a Turkic locale, these are problematic because their mappings
cross the 255/256 boundary.
This change has the side effect of causing U+307 to be added to the
problematic list, and it normally really isn't problematic, because in
those locales where U+130 and U+131 are problematic, U+307 isn't used.
But applications could switch in and out of Turkic locales, so it's best
to leave it be considered problematic. The consequences of making this
mark problematic are simply slightly less optimized regex pattern code.
Karl Williamson [Tue, 5 Feb 2019 05:09:31 +0000 (22:09 -0700)]
sv_utf8_upgrade_flags_grow(): Alloc extra byte if empty
People may call this expecting that the 'extra' parameter is on top of
whatever is in there. If something is in there, that already includes a
NUL, but if nothing is in there, for safety, add a byte to the request.
Karl Williamson [Tue, 5 Feb 2019 01:27:38 +0000 (18:27 -0700)]
regcomp.c: Clarify comment
Karl Williamson [Tue, 5 Feb 2019 05:13:16 +0000 (22:13 -0700)]
pp.c: Clarify comment
David Mitchell [Tue, 5 Feb 2019 14:04:32 +0000 (14:04 +0000)]
[MERGE] various overload fixups
This branch contains several commits which simplify the code concerning
the processing of a value returned by an overload method, and
specifically whether that value should be returned as-is by the op, or
assigned to the targ / stack value: $lex = x op y) and (x op= y)
respectively.
The final commit fixes a bug in pp_multiconcat. That op bypasses most of
the code in those earlier commits and "rolls it's own", and which was
getting the set/assign decision wrong in some cases, causing a leak.
David Mitchell [Tue, 5 Feb 2019 13:48:21 +0000 (13:48 +0000)]
Avoid leak in multiconcat with overloading.
RT #133789
In the path taken through pp_multiconcat() when one or more args have
side-effects such tieing or overloading, multiconcat has to decide
whether to just return the result of all the concatting as-is, or to
first assign it to an expression or variable if the op includes an
implicit assign (such as $lex = x.y.z or $a[0] = x.y.z).
The code was getting this right for those two cases, and was also
getting it right for the append cases ($lex .= x.y.z and $a[0] .= x.y.z),
which don't need assigns. But for the bare case (x.y.z) it was assigning
to the op's targ as well as returning the value. Hence leaking a
reference until destruction of the sub and its pad.
This commit stops the assign in that last case.
David Mitchell [Mon, 4 Feb 2019 15:17:02 +0000 (15:17 +0000)]
Perl_try_amagic_un/bin re-indent
After the previous commit's simplification, eliminate a set of braces and
re-indent a block of code.
David Mitchell [Mon, 4 Feb 2019 15:07:11 +0000 (15:07 +0000)]
Eliminate AMGf_set flag
I added this flag a few years ago when I revamped the overload macros
tryAMAGICbin() etc. It allowed two different classes of macros to
share the same functions (Perl_try_amagic_un/Perl_try_amagic_bin)
by indicating what type of action is required.
However, the last few commits have made those two functions able to
robustly always determine whether its an assign-type action
($x op= $y or $lex = $x op $x) or a plain set-result-on-stack operation
($x op $y).
So eliminate this flag.
Note that this makes the ops which have the AMGf_set flag hard-coded
infinitesimally slower, since Perl_try_amagic_bin no longer skips the
checks for assign-ness. But compared with the overhead of having
already called the overload method, this is is trivial.
On the plus side, it makes the code smaller and easier to understand.
David Mitchell [Mon, 4 Feb 2019 14:52:01 +0000 (14:52 +0000)]
Perl_try_amagic_bin(): eliminate dATARGET
.. and replace with explicit tests and assigns to targ.
This macro includes an OPf_STACKED test which has already been done
above. Also, by protecting the OPf_STACKED test within a AMGf_assign
test, we can eliminate the AMGf_set flag in the next commit, and use the
same set of code for both AMGf_set and AMGf_assign variant calls to
Perl_try_amagic_bin().
David Mitchell [Mon, 4 Feb 2019 14:11:13 +0000 (14:11 +0000)]
Eliminate SvPADMY tests from overload code
A couple of places in the overload code do SvPADMY(TARG) to decide
whether this is a normal op like ($x op $y), where the targ will have
SVs_PADTMP set, or a lexical assignment like $lex = ($x op $y) where the
assign has been optimised away and the op is expected to directly assign
to the targ which it thinks is a PADTMP but is really $lex.
Since the SVs_PADMY flag was eliminated a while ago, SvPADMY() is just
defined as !(SvFLAGS(sv) & SVs_PADTMP). Thus the overload code is
relying on the absence of a PADTMP flag in the target to deduce that the
OPpTARGET_MY optimisation is in effect. This seems to work (at least for
the code in the test suite), but can't be regarded as robust. This
commit removes each SvPADMY() test and replaces it with the twin
if ( (PL_opargs[PL_op->op_type] & OA_TARGLEX)
&& (PL_op->op_private & OPpTARGET_MY))
tests.
David Mitchell [Mon, 4 Feb 2019 13:48:13 +0000 (13:48 +0000)]
Eliminate opASSIGN macro usage from core
This macro is defined as
(PL_op->op_flags & OPf_STACKED)
and indicates, for ops which support it, that the mutator-variant of the
op is present (e.g. $x += 1).
This macro was mainly used as an arg for the old-style overloading
macros (tryAMAGICbin()) which were eliminated several years ago.
This commit removes its vestigial usage, and instead tests OPf_STACKED
directly at each location, along with adding a comment about the
significance of the flag.
This removes one item of obfuscation from the overloading code.
There is one potentially functional change in this commit:
Perl_try_amagic_bin() was sometimes testing for OPf_STACKED without
first checking that it had been called with the AMGf_assign flag (which
indicates that this op supports a mutator variant). With this commit, it
now checks first, so this is theoretically a bug fix. In practice that
section of code was never reached without AMGf_assign always being set
anyway.
Tony Cook [Tue, 5 Feb 2019 08:40:53 +0000 (19:40 +1100)]
(perl #133824) fix threading builds
I failed to test the build with threads.
Karl Williamson [Fri, 1 Feb 2019 15:48:20 +0000 (08:48 -0700)]
regen/unicode_constants.pl: generate UTF-8 for U+307
This will be needed in a future commit
Karl Williamson [Fri, 1 Feb 2019 15:29:51 +0000 (08:29 -0700)]
t/loc_tools.pl: Add fcn to return all UTF-8 locales
This will be needed in future commits
Karl Williamson [Fri, 1 Feb 2019 18:45:34 +0000 (11:45 -0700)]
pp.c: White-space only
Indent block newly formed in the previous commit
Karl Williamson [Fri, 1 Feb 2019 18:43:10 +0000 (11:43 -0700)]
pp.c: Avoid use of unsafe function
The function is unsafe because it doesn't check for running off the end
of the buffer if presented with illegal UTF-8. The only remaining use
now is from mathoms.c.
Karl Williamson [Fri, 1 Feb 2019 18:41:14 +0000 (11:41 -0700)]
pp.c: Add branch prediction hint
This conditional is very rarely true
Karl Williamson [Wed, 30 Jan 2019 18:24:12 +0000 (11:24 -0700)]
pp.c: Don't assume worst case memory needs
Since 5.28, there has been a function that will calculate the expansion
of a string when converted into UTF-8, using per-word operations. This
means it runs 8 times faster than doing this count previously would have
taken.
I've come to believe it is better to calculate how much memory we need
than to overallocate based on worst-case scenarios. This is because in
very large strings, over allocating can lead to unnecessary inefficient
processing.
This commit changes several instances in pp.c where a string needs to be
converted to UTF-8 to not assume the worst case, but instead calculate
what's needed using the faster function.
Karl Williamson [Wed, 30 Jan 2019 18:09:01 +0000 (11:09 -0700)]
pp.c: Don't use function call for easy copy
Like the previous commit, this code is adding the UTF-8 for a Greek
character to a string. It previously used Copy, but this character is
representable as two bytes in both ASCII and EBCDIC UTF-8, the only
character sets that Perl will ever supports, so we can use the
specialized code that is used most everywhere else for two byte UTF-8
characters, avoiding the function overhead, and having to treat this
character as particularly special.
Karl Williamson [Wed, 30 Jan 2019 17:52:41 +0000 (10:52 -0700)]
pp.c: Don't use function call for easy copy
This code is adding the UTF-8 for a Greek character to a string. It
previously used Copy, but this character is representable as two bytes
in both ASCII and EBCDIC UTF-8, the only character sets that Perl will
ever supports, so we can use the specialized code that is used most
everywhere else for two byte UTF-8 characters, avoiding the function
overhead, and having to treat this character as particularly special.
Karl Williamson [Wed, 30 Jan 2019 17:35:21 +0000 (10:35 -0700)]
pp.c: pp_fc(): Simplify
The function being called does everything that the code being eliminated
here did. We just pass the function the final destination instead of a
temporary.
Karl Williamson [Wed, 30 Jan 2019 17:27:17 +0000 (10:27 -0700)]
pp.c: White-space, comments only
Karl Williamson [Wed, 30 Jan 2019 17:02:35 +0000 (10:02 -0700)]
pp.c: Reorder clause order in an 'if'
This makes the test most likely to fail be first, and adding an
UNLIKELY() to it, thus saving a conditional in most instances.
Karl Williamson [Wed, 30 Jan 2019 05:02:59 +0000 (22:02 -0700)]
pp.c: Use faster method to convert to UTF-8
There is a special inline function that's used when converting a single
byte to UTF-8, that is faster than the more general one used prior to
this commit.
Karl Williamson [Wed, 30 Jan 2019 05:01:18 +0000 (22:01 -0700)]
pp.c: Add missing assert
The comments say there is an assert, but it wasn't there.
Karl Williamson [Mon, 4 Feb 2019 23:02:35 +0000 (16:02 -0700)]
t/op/lc.t: Add 'use strict'
Karl Williamson [Wed, 30 Jan 2019 05:25:03 +0000 (22:25 -0700)]
t/re/fold_grind.pl: White-space only
Just align some logical or clauses for readability.
Karl Williamson [Wed, 30 Jan 2019 16:08:13 +0000 (09:08 -0700)]
handy.h: Add comment
Karl Williamson [Fri, 25 Jan 2019 16:55:58 +0000 (09:55 -0700)]
handy.h: White-space only
Vertically align the ternary colon with the question mark above it.
Karl Williamson [Wed, 23 Jan 2019 22:42:35 +0000 (15:42 -0700)]
handy.h: Add void * casts to memEQ, memNE
This change is to allow these macros to be called without having to do
casting in the call.
Karl Williamson [Wed, 30 Jan 2019 22:00:30 +0000 (15:00 -0700)]
regcomp.c: Fix recent optimization of [...] bug
This bug was introduced in
b2296192536090829ba6d2cb367456f4e346dcc6
n 5.29.7. Using /il should not result in looking for a [:posix:] class
that matches the code points given.
Tony Cook [Mon, 4 Feb 2019 23:39:57 +0000 (10:39 +1100)]
(perl #133462) add specific test run instructions to README.win32
README.win32 provides generally standalone instructions for running
and testing perl, but unlike INSTALL didn't provide instructions
for repeating individual tests.
Both perlguts and INSTALL provide instructions on repeating individual
tests, and considering at the point a user want this information they
don't have a working perl installation, I think it's reasonable to
repeat it here.
Tony Cook [Mon, 4 Feb 2019 23:19:51 +0000 (10:19 +1100)]
(perl #108276) reduce recursion on ops
This can prevent stack overflow when processing extremely deep op
trees.
Tony Cook [Tue, 29 Jan 2019 05:29:38 +0000 (16:29 +1100)]
(perl #108276) optimize child ops in sibling order
Tony Cook [Wed, 30 Jan 2019 00:06:52 +0000 (11:06 +1100)]
(perl #108276) indent optimize_op() loop body
Tony Cook [Tue, 29 Jan 2019 05:29:04 +0000 (16:29 +1100)]
(perl #108276) remove recursion from optimize_op()
The prevented code like:
./miniperl -e 'my $line = "\$cond ? \$a : \n"; my $code = ($line x 100000) . "\$b;\n"; eval $code;'
from crashing due to stack overflow.
It does however take a long time to compile.
Because it doesn't strictly recurse through the op tree (due
to OP_SUBST), I couldn't use traverse_op_tree().
I considered wrapping a traverse_op_tree() loop inside a defer op
loop, so OP_SUBST would defer its op, but processing order is
somewhat important from setting PL_curcop.
This also processes the child ops in reverse order, I'm not sure if
that's a real problem (no tests failed), but the next commit fixes
that order.
Tony Cook [Tue, 29 Jan 2019 04:03:43 +0000 (15:03 +1100)]
(perl #108276) add wrappers for deferred op processing
To avoid duplication of the declarations.
Tony Cook [Tue, 29 Jan 2019 03:22:02 +0000 (14:22 +1100)]
(perl #108276) indent body of new finalize_op() loop
Tony Cook [Tue, 29 Jan 2019 02:57:51 +0000 (13:57 +1100)]
(perl #108276) eliminate recursion from finalize_op()
whitespace in next commit
James E Keenan [Mon, 4 Feb 2019 14:11:09 +0000 (09:11 -0500)]
Grammatical correction only.
Sentences ending with a parenthetical phrase that ends
with an abbreviation such as 'etc.' still require a period
outside of the parentheses.
See https://english.stackexchange.com/a/23025/306017
For: RT 133820. Christopher Chavez is now a Perl author.
Andy Dougherty [Thu, 31 Jan 2019 19:05:41 +0000 (14:05 -0500)]
Define _GNU_SOURCE if using the musl libc on linux.
Together with prior commits
ba73a4cb8f,
f8d82a1010, and
63c1fa6a98,
this should close [perl #133760].
Andy Dougherty [Thu, 31 Jan 2019 18:04:32 +0000 (13:04 -0500)]
Improve detection of memrchr, strlcat, and strlcpy.
This is continuation of commit
f8d82a1010 addressing [perl #133760].
Linux systems using the musl C library have memmem, memrchr, strlcat, and
strlcpy, but the prototypes are only visible if _GNU_SOURCE is defined.
This patch makes Configure test both whether the prototype is visible
and whether the C symbol is visible.
Still to be done is automatically adding _GNU_SOURCE if the musl library
is being used -- probably in hints/linux.sh.
Chris 'BinGOs' Williams [Thu, 31 Jan 2019 09:12:29 +0000 (09:12 +0000)]
Update Encode to CPAN version 3.00
[DELTA]
$Revision: 3.00 $ $Date: 2019/01/31 04:51:32 $
! Encode.pm
VERSION bumped to 3.00 to make PAUSE happy
2.100 2019/01/31 04:26:40
! Encode.xs MANIFEST
+ t/xml.t
Pulled: Do not access SV* buffer if we have not called SvPV_force()
https://github.com/dankogai/p5-encode/pull/137
! MANIFEST
remove utf8messages.t which is already deleted from the repository.
James E Keenan [Fri, 30 Nov 2018 15:33:07 +0000 (10:33 -0500)]
If comparison is always true, while (1) should suffice.
Per suggestion by Dave Mitchell in RT 133703, re-implemented in RT
133744.
Tony Cook [Tue, 29 Jan 2019 23:20:08 +0000 (10:20 +1100)]
perldelta for
d4c456e337e6
Tony Cook [Mon, 21 Jan 2019 00:41:03 +0000 (11:41 +1100)]
(perl #133782) set magic when changing $^R
The regexp engine sets and restores $^R in a few places, but didn't
mg_set() (SvSETMAGIC()) it at all.
Calls to length() on $^R, both within regexp code blocks and on
a successful match could add utf8 length magic to $^R, and modifying
$^R without mg_set() could leave now invalid length magic.
Karl Williamson [Mon, 28 Jan 2019 09:28:25 +0000 (02:28 -0700)]
Split t/re/fold_grind.t into multiple test files
This has been a goal for a long time, but I thought it would be a lot of
work, but now have realized that there was a fairly easy simplistic
approach.
The core file is renamed fold_grind.pl. It formerly had an outer loop
which iterated over the possible character set regex pattern modifiers,
/a, /l, etc that were tested. Now that loop is just a block and new
wrapper files have been created, one per modifier. They just pass a
global to the core file that gives which modifier this test file is to
use. Hence each file corresponds to one iteration of the old outer
loop, splitting the tests up into 6 smaller tests that can run in
parallel.
Chris 'BinGOs' Williams [Tue, 29 Jan 2019 20:02:22 +0000 (20:02 +0000)]
Update Test-Simple to CPAN version 1.302161
[DELTA]
1.302161 2019-01-29 09:34:27-08:00 America/Los_Angeles (TRIAL RELEASE)
- Remove SHM Optimization
Tony Cook [Tue, 29 Jan 2019 05:44:01 +0000 (16:44 +1100)]
bump $IO::VERSION
Shlomi Fish [Sun, 27 Jan 2019 08:53:32 +0000 (10:53 +0200)]
Avoid indenting POD paragraphs in dist/IO
It is considered monospaced code blocks and was misformatted by
metacpan/etc.
Submitted via https://github.com/toddr/IO/pull/49
Signed-off-by: Todd Rinaldo <toddr@cpan.org>
Chris 'BinGOs' Williams [Mon, 28 Jan 2019 14:31:57 +0000 (14:31 +0000)]
Update perlfaq to CPAN version 5.
20190126
[DELTA]
5.
20190126 2019-01-26 04:39:37Z
* Many typos and pod markup fixed (PR#75, #76) thanks, Joaquin Ferrero!)
* Added reference in perlfaq to new ~ syntax in indented here-docs (PR#77,
thanks Celejar!)
Tony Cook [Mon, 28 Jan 2019 03:11:50 +0000 (14:11 +1100)]
don't leak temp files
the test I added allocated more temp files, but didn't arrange for
backup files to be cleaned up.
Modified the cleanup to clean up every generated temp and backup file
even if more are allocated in the future with mkfiles()
Tony Cook [Thu, 24 Jan 2019 23:32:42 +0000 (10:32 +1100)]
PERL_OP_PARENT is always defined, stop testing for it
PERL_OP_PARENT is the new reality, leaving the pre-processor
checks is more confusing that anything else.
I left the test in perl.c for consistency with the other checks in that
code.
Andy Dougherty [Thu, 24 Jan 2019 02:39:39 +0000 (21:39 -0500)]
Another attempt to improve Configure detection of memmem() [perl #133760].
This updates commit
ca152fd8207cf53816b1407d5f54f6ea160a3ef8.
Linux systems have memmem, but the prototype in <string.h> is only
visible if __GNU_SOURCE is defined. This version tests for both the
prototype in <string.h> and the symbol in libc. (Thanks to Tony C. for
the suggestion.) (For BSD systems, no extra define is needed.)
Andy Dougherty [Thu, 24 Jan 2019 02:12:29 +0000 (21:12 -0500)]
Add ability to include literal text in the prototype check.
This is the same technique as in the metaconfig unit Protochk.U.
See that unit for more usage information. It is a bit clunky,
but does work.
James E Keenan [Wed, 16 Jan 2019 15:56:44 +0000 (10:56 -0500)]
find.t: Use temporary testing directory for all blocks of tests.
During the execution of ext/File-Find/t/taint.t certain files and directories
are created. As inferred from smoke-test reports, when testing in parallel
these entities ran the risk of being detected by certain tests in
ext/File-Find/t/find.t, thereby causing intermittent failures in the smoke
tests.
Problem is being addressed by (a) moving the block of tests created in August 2014
(RT #122547) to prevent processing of misspelled options to a place in the
file where we have moved from the current working directory one level down to
a temporary testing directory; and (b) providing a list of basenames of files
we expect to find therewithin.