This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Karl Williamson [Sat, 11 Jan 2020 04:46:33 +0000 (21:46 -0700)]
utf8.c: Use already-computed variable
instead of doing it a second time
Karl Williamson [Fri, 17 Jan 2020 18:51:32 +0000 (11:51 -0700)]
Refactor grok_number_flags to speed it up
This uses a variety of techniques to improve the performance.
The chief one is to switch on the input length for the unrolled part of
the loop, like is done in grok_bin_oct_hex(). This eliminates having to
check if we are at the end of the string each time we process and
advance a digit through it.
Explicit branch predictions were added. One assumes that the input
won't have a sign more frequently than it does have one.
Some setup conditionals were eliminated. One way is that this ignores
leading spaces. Previously, it just advanced through any and then
checked if we are at the end of the string after having done so. That
check can be eliminated if we didn't advance.
Also, I check for a sign with a single conditional, eliminating a check
for minus, then, if not found, one for plus. Instead, if it is a sign,
there is an extra check for which one. Thus it rewards unsigned input,
and penalizes signed, by a single conditional each way.
James E Keenan [Sat, 18 Jan 2020 14:13:09 +0000 (09:13 -0500)]
perldelta for commit
9c952fa3
Russ Allbery [Sat, 18 Jan 2020 14:11:44 +0000 (09:11 -0500)]
Sync with CPAN version 5.01 of Term::ANSIColor
Dan Book [Mon, 13 Jan 2020 21:49:05 +0000 (16:49 -0500)]
Create crosslinks betwen perlrun sections
Tomasz Konojacki [Fri, 17 Jan 2020 20:32:55 +0000 (21:32 +0100)]
move and clean-up macros wrapping __attribute__()
__attribute__() detection fallback for non-Configure platforms
(such as Windows) in perl.h was moved above the PERL_UNUSED_DECL
definition. That fixed two problems:
- PERL_UNUSED_DECL was undefined on those platforms
- __attribute__* macros weren't working properly inside headers
included above their definitions (e.g. "win32.h")
Also, redundant checks for pre-3.4 g++ versions were removed.
James E Keenan [Fri, 17 Jan 2020 23:16:40 +0000 (18:16 -0500)]
Chad Granum [Fri, 17 Jan 2020 23:14:31 +0000 (18:14 -0500)]
Sync Test-Simple with CPAN version 1.302171
Nicolas R [Fri, 17 Jan 2020 21:07:41 +0000 (14:07 -0700)]
Define env correctly for GitHub workflow jobs
Environment variables were defined too early.
This is moving them inside the job, and add
the CONTINUOUS_INTEGRATION=1 variable.
Nicolas R [Fri, 17 Jan 2020 18:46:38 +0000 (11:46 -0700)]
Skip t/porting/authors.t when failing guessing common ancestor
Nicolas R [Fri, 17 Jan 2020 17:31:35 +0000 (10:31 -0700)]
Disable dist/IO/t/io_sock.t on windows
Fixes #17429
Test is out of sequence.
Note: ENV were set too early.
Craig A. Berry [Fri, 17 Jan 2020 18:20:42 +0000 (12:20 -0600)]
Fix DEBUGGING check in Devel-PPPort/t/utf8.t
Devel::PPPort claims to support Perl back to 5.003_07, which means
that we can't use a more rational method here such as
Config::non_bincompat_options().
Chase Whitener [Mon, 20 Nov 2017 23:31:30 +0000 (18:31 -0500)]
Update documentation for IO::Socket.
* Get rid of the POD errors as well as the useless `NOTE NOTE NOTE`
lines that were littered throughout.
* Provide documentation and useful examples for each and every
single constructor argument.
* Provide documentation for all methods made available.
* Where it makes sense, provide links to other documents that
explain what the module is doing.
Previously, this relied heavily on the user knowing what they were
doing, rendering the documentation mostly pointless.
While this is not yet perfect, it's better than what we had before
and should be of help to developers of all skill levels.
Hugo van der Sanden [Thu, 16 Jan 2020 15:42:05 +0000 (15:42 +0000)]
study_chunk: generate ANYOFM here rather than in join_exact()
When we detect an EXACTFish node cannot be extended by joining with others,
and is short and simple enough, we want to replace it with ANYOFM.
Prefer to do that in the study_chunk() handling of EXACTFish nodes: this
isn't part of join_exact's responsibilities (and is not documented there),
and moving it will make subsequent refactoring easier.
Note that this means it will no longer happen earlier as part of the
experimental regtail_study() call to join_exact(), currently invoked
only if perl is built with PERL_ENABLE_EXPERIMENTAL_REGEX_OPTIMISATIONS.
Chris 'BinGOs' Williams [Tue, 14 Jan 2020 19:48:52 +0000 (19:48 +0000)]
Update ExtUtils-MakeMaker to CPAN version 7.44
[DELTA]
7.44 Tue 14 Jan 16:35:06 GMT 2020
No changes since v7.43_01
7.43_01 Sun 5 Jan 12:41:43 GMT 2020
Bug fixes:
- Match final dir component in init_MANPODS
Test Fixes:
- Use internal reference to Makefile in build_man.t
Karl Williamson [Mon, 13 Jan 2020 16:01:08 +0000 (09:01 -0700)]
utf8.c: Change variable types so compiles on Solaris
This was made necessary by
40d2776f3505d22a2b1309ae2c3bf28bcb1d9016
Karl Williamson [Mon, 13 Jan 2020 17:11:42 +0000 (10:11 -0700)]
regen/reentr.pl: Use Configure'd types
Configure goes to the trouble of finding the parameter types that the
gethostbyFOO functions use, but reentr.pl was ignoring this, causing
compilation failures on at least Solaris.
Karl Williamson [Tue, 14 Jan 2020 03:59:17 +0000 (20:59 -0700)]
Merge branch 'grok_bin_oct_hex' into blead
This branch collapses 3 very similar functions into one, for easier
maintenance. The resulting function is then modified to improve
performance over blead, and documentation is clarified.
Karl Williamson [Fri, 10 Jan 2020 18:45:39 +0000 (11:45 -0700)]
Improve performance of grok_bin_oct_hex()
This commit uses a variety of techniques for speeding this up. It is
now faster than blead, and has less maintenance cost than before.
Most of the checks that the current character isn't NUL are unnecssary.
The logic works on that character, even if, for some reason, you can't
trust the input length. A special test is added to not output the
illegal character message if that character is a NUL. This is simply
for backcompat.
And a switch statement is used to unroll the loop for the leading digits
in the number. This should handle most common cases. Beyond these, and
one has to start worrying about overflow. So this version has removed
that worrying from the common cases.
Extra conditionals are avoided for large numbers by extracting the
portability warning message code into a separate static function called
from two different places. Simplifying this logic led me to see that if
it overflowed, it must be non-portable, so another conditional could be
removed.
Other conditionals were removed at the expense of adding parameters to
the function. This function isn't public, but is called from the
grok_hex, et. al. macros. grok_hex knows, for example, that it is
looking for an 'x' prefix and not a 'b'. Previously the code had a
conditional to determine that.
Similarly in pp.c, we look for the prefix. Having found it we can start
the parse after the prefix, and tell this function not to look for it.
Previously, this work was duplicated.
The previous changes had left this function slower than blead. That is
in part due to the fact that the loop doesn't go through that many
iterations per function call, and the gcc compiler managed to optimize
away the conditionals in XDIGIT_VALUE in the call of it from the loop.
(The other call in this function did have the conditionals.)
Thanks to Sergey Aleynikov for his help on this
Karl Williamson [Sun, 12 Jan 2020 23:05:03 +0000 (16:05 -0700)]
numeric.c: Slight restructure grok_bin_oct_hex
This saves the input flags into a local variable and uses that in the
rest of the function, and initializes the output flags at the beginning
of the functions. This is in preparation for more output flags to be
set, as we go along.
Karl Williamson [Wed, 8 Jan 2020 18:55:35 +0000 (11:55 -0700)]
numeric.c: White-space only
Outdent code whose enclosing block was removed by the previous commit.
A few other white space fixups.
Karl Williamson [Wed, 8 Jan 2020 18:54:18 +0000 (11:54 -0700)]
grok_bin_oct_hex: better ovrflw accuracy; rmv loop cond.
This removes a conditional in the loop, and improves the accuracy of the
overflow NV returned that approximates the desired input.
Karl Williamson [Sun, 12 Jan 2020 23:48:34 +0000 (16:48 -0700)]
perlapi: Move documentation
This flag doesn't actually occur in the functions in which the
documentation for it is mentioned. Instead, move it to a function that
does mention it.
Karl Williamson [Sun, 12 Jan 2020 23:47:19 +0000 (16:47 -0700)]
perlapi: Update grok_bin, _oct, _hex
In examining these functions in detail, I found some things in the pod
that were unclear or misleading. This is an attempt to clarify things.
Karl Williamson [Wed, 8 Jan 2020 03:37:17 +0000 (20:37 -0700)]
numeric.c: Move function in the file
This makes adjacent all similar functions and their docs
Karl Williamson [Sun, 5 Jan 2020 02:07:47 +0000 (19:07 -0700)]
numeric.c: Fix typos in comments
Karl Williamson [Tue, 7 Jan 2020 01:49:41 +0000 (18:49 -0700)]
grok_bin_oct_hex(): Add branch prediction
Karl Williamson [Tue, 7 Jan 2020 00:32:35 +0000 (17:32 -0700)]
Collapse grok_bin, _oct, _hex into one function
These functions are identical in logic in the main loop, the difference
being which digits they accept. The rest of the code had slight
variations. This commit unifies the functions.
I presume the reason they were kept separate was because of speed.
Future commits will make this unified function faster than blead, and
the reduced maintenance cost makes this worthwhile.
Karl Williamson [Mon, 6 Jan 2020 23:51:43 +0000 (16:51 -0700)]
l1_char_class_tab.h: Add bits for binary, octal digits
The motivation behind these extra bits is to allow three functions that
deal with, respectively, binary, octal, and hex data to use the same
paradigm, and hence be collapsible into a single function.
Karl Williamson [Mon, 6 Jan 2020 22:22:29 +0000 (15:22 -0700)]
handy.h: Convert XDIGIT_VALUE to branchless
This removes a branch and an array lookup in the XDIGIT_VALUE() macro.
It adds some shifts, masks, and additions instead, though replacing a
mask and addition in the old way.
A somewhat more complicated version could be made for EBCDIC, but I'm
not bothering to do that, using an array lookup to convert the salient
value to ASCII, so on EBCDIC there isn't an array lookup removal.
Karl Williamson [Sun, 12 Jan 2020 17:11:54 +0000 (10:11 -0700)]
Rewrite and inline my_strnlen()
This commit changes this function to use memchr() instead of looping
byte-by-byte through the string. And it inlines it into 3 lines of
code. This should give comparable performance to a native libc
strnlen().
Hugo van der Sanden [Mon, 13 Jan 2020 16:39:57 +0000 (16:39 +0000)]
study_chunk: tweaks to separate bytelen, charlen for EXACTish
cast to avoid warning; avoid an additional utf8_length() call.
Smylers [Mon, 13 Jan 2020 11:32:08 +0000 (11:32 +0000)]
FIx apostrofly
A possessive apostrophe needs an actual letter ‘S’, not just the ‘S’ sound at the end of “POSIX”.
Rewrite as “the POSIX module's”, to make it clearer. And link the function name.
David Mitchell [Mon, 13 Jan 2020 14:04:38 +0000 (14:04 +0000)]
Tie::File: use unique tmp filenames in test files
Currently all the test scripts use a temporary file of the form
"tf$$.txt", which could possibly cause clashes between test scripts
on platforms where the PID cycles frequently. This commit gives each
test file its own unique tmp-filename prefix, e.g. 42_offset.t now has
my $file = "tf42-$$.txt";
I probably should have switched over completely to using File::Temp,
but this was a smaller change, and I haven't tested it on older perls.
The motivation for this is occasional test failures of 29a_upcopy.t on
some smokes. Whether this commit fixes that, only time will tell.
Karl Williamson [Sat, 11 Jan 2020 17:55:08 +0000 (10:55 -0700)]
perldiag: Clarify statement
The statement about the future needs to be less certain as to what might
happen.
Karl Williamson [Sat, 11 Jan 2020 17:53:57 +0000 (10:53 -0700)]
perldiag: Rmv obsolete statement
Code points this large are no longer legal on a 32 bit platform.
Karl Williamson [Mon, 13 Jan 2020 04:07:35 +0000 (21:07 -0700)]
util.c: Rmv now always-true assertion
Commit
052d914306c3a13afe3fbeb17c8f1c986969f94c changed the type of this
parameter to unsigned, so it is now never negative.
Tony Cook [Sun, 5 Jan 2020 23:32:28 +0000 (10:32 +1100)]
don't suggest using the perl malloc() implementation in perlguts
1. the suggestion doesn't really belong here
2. the usemymalloc implementation is typically slower than a
modern system malloc().
Hugo van der Sanden [Sun, 12 Jan 2020 18:01:46 +0000 (18:01 +0000)]
study_chunk: separate bytelen, charlen for EXACTish study
Make things slightly clearer.
Nicolas R [Tue, 31 Dec 2019 21:55:32 +0000 (14:55 -0700)]
Add update action to Porting/checkAUTHORS.pl
Fixes #17206
AUTHORS can now be updated by 'Porting/checkAUTHORS.pl' using
the new 'update' action.
Example: perl Porting/checkAUTHORS.pl --update --from=v5.31.6
The changes to the file AUTHORS is better read by ommitting whitespaces.
The changes to AUTHORS are the following:
- authors are sorted
- some emails changed to reflect the preferred email set in the <DATA> section
of checkAUTHORS.pl
When detecting a new author, we will list the GitHub account instead of the email.
Anyone can replace his email by the GitHub account by directly editing AUTHORS file.
Note that the <DATA> section has been adjusted to accomodate several
existing emails in the AUTHORS file to avoid selecting a different email.
'Hio' was listed twice and we preserved the preferred email address.
Hugo van der Sanden [Fri, 10 Jan 2020 13:56:06 +0000 (13:56 +0000)]
study_chunk: remove JOIN_EXACT macro
It's used only once, and the code is clearer when we can see the condition
it applies.
Hugo van der Sanden [Fri, 10 Jan 2020 13:56:06 +0000 (13:56 +0000)]
study_chunk: simplify PAREN_TEST and related macros
Define PAREN_OFFSET to point to the bitvector for the relevant depth, update
PAREN_TEST, PAREN_SET and PAREN_UNSET to take a depth instead of a pointer,
and simplify the various users.
Hugo van der Sanden [Fri, 10 Jan 2020 13:56:06 +0000 (13:56 +0000)]
study_chunk: declare final_minlen earlier
This simplifies slightly, and makes room for further refactoring.
Nicholas Clark [Fri, 10 Jan 2020 11:19:44 +0000 (12:19 +0100)]
Fix a small grammar error in perl5240delta.pod
Also remove some trailing spaces.
Nicholas Clark [Fri, 10 Jan 2020 08:42:55 +0000 (09:42 +0100)]
Fix a typo in perl5260delta.pod.
Yves Orton [Thu, 9 Jan 2020 14:36:41 +0000 (15:36 +0100)]
Fix Issue #17372 - Deal with NOTHING regops in trie code properly
We weren't handling NOTHING regops that were not followed
by a trieable type in the trie code.
Todd Rinaldo [Wed, 8 Jan 2020 23:50:35 +0000 (17:50 -0600)]
Remove autodie t/no-all.t tests from Porting/Maintainers.pl
This test requires a module not shipped with core.
Chris 'BinGOs' Williams [Thu, 9 Jan 2020 12:02:03 +0000 (12:02 +0000)]
Update autodie to CPAN version 2.31
[DELTA]
2.31 2020-01-08 00:37:45-06:00 America/Chicago
* TEST BUGFIX: Correct diag explain in t/version.t
so it'll pass on perl 5.8
* TEST BUGFIX: Only test t/no-all.t if optional
IPC::System::Simple is available
* BUILD: Switch automated testing to github actions
* TEST BUGFIX: Turn off t/kill.t for windows. Recent
versions of windows seem to choke when doing:
`kill 0, $$;`
2.30 2020-01-02 16:51:16-06:00 America/Chicago
* BUGFIX: Fix a boolean logic precedence error causing
a "useless use of numeric" warning when using kill
with a signal of 0. Thanks to Maurice Aubrey for
reporting the issue and providing a Pull Request
for it. (GH#76)
* BUGFIX: Apply patch from Niko Tyni to fix a scoping
issue "no autodie" and the "system" sub. (GH#69)
* BUGFIX / DOC: Update code and documentation about
smartmatch to match current the current support
in perl. Thanks to Zefram; cherry-picked from
perl core. (GH#83)
* DOC: Fix a POD error and some unnecessary spaces
that tripped POD parsers. Thanks to Aaron Crane
and Chase Whitener for reporting the issues plus
providing Pull Requests for it. (GH#51 and GH#79)
* DOC: Document how to use Import::Into with autodie.
(GH#50)
* BUILD: Clean up of dzil.ini removing some unnecessary
test recommends. Thanks to Karen Etheridge for
reporting the issue and providing a Pull Requests
for it. (GH#78)
* TEST BUGFIX: Set binmode on some file handles to fix
issues on Windows. Thanks to Tony Cook; cherry-picked
from perl core. (GH#83)
* TEST / INTERNAL / TRAVIS: Also test with Perl 5.22,
5.24, 5.26 and 5.28.
Dan Book [Wed, 18 Dec 2019 21:25:50 +0000 (16:25 -0500)]
Document suggestion to use libffi for simple library bindings
Karl Williamson [Sun, 5 Jan 2020 02:06:09 +0000 (19:06 -0700)]
perlapi: Perl_isinfnan: fix typo
Karl Williamson [Sat, 4 Jan 2020 18:23:35 +0000 (11:23 -0700)]
embed.fnc: Fix typo in comment
Karl Williamson [Sat, 4 Jan 2020 17:49:22 +0000 (10:49 -0700)]
regcomp.c: White-space only
Karl Williamson [Sat, 4 Jan 2020 17:48:46 +0000 (10:48 -0700)]
embed.fnc: Remove wrong 'const'
This parameter isn't const
Karl Williamson [Sat, 4 Jan 2020 17:40:56 +0000 (10:40 -0700)]
Change len param in savepvn to Size_t from I32
We handle longer strings than 31 bits.
Santtu Ojanperä [Sun, 1 Dec 2019 01:45:27 +0000 (03:45 +0200)]
Made string multiplication more clear in perlintro
Added "repeats strings" in parenthesis to make it more unambiguous.
Santtu Ojanperä is now a Perl author.
For: https://github.com/Perl/perl5/pull/17335
Chris 'BinGOs' Williams [Tue, 7 Jan 2020 11:58:07 +0000 (11:58 +0000)]
Update podlators to CPAN version 4.14
[DELTA]
podlators 4.14 (2020-01-04)
Document that parse_lines and parse_string_document expect raw bytes,
not decoded characters.
Fix the test suite use of parse_string_document to pass in raw bytes
rather than decoded characters, which will hopefully fix test failures
with versions of Pod::Simple older than 3.22 and is a more correct
test of encoding handling.
Chris 'BinGOs' Williams [Tue, 7 Jan 2020 11:54:15 +0000 (11:54 +0000)]
Update DB_File to CPAN version 1.853
[DELTA]
1.853 5 January 2020
* Memory leak if ParseOpenInfo calls croak_and_free
https://github.com/pmqs/DB_File/issues/3
9e2c8d6c3a35acb71358f440c93defa3d8339420
* Add Address Sanatizer suppressions file
a6a26f4878d6be13aad69a3f5b6019e7482a8992
* Add prereq test
a631884b3ca11919142c6be8a64e668730b83469
* Documemtation updates
4c53b38531b547ae293967c852ff21412eb6d840
* clang warning in ppport.h
update to latest ppport.h
https://github.com/pmqs/DB_File/issues/2
36d6ae54edfc1df872f5e66c93bda05cbfefefa7
* #125853 - RT links in Changes file are wrong
Changes entry for 1.842 has both CPAN & Perl RT links.
Use the full URL to avoid ambiguity.
f06a9235373747d0f5c6a95caf504174ffb19c44
Tony Cook [Mon, 6 Jan 2020 22:46:01 +0000 (09:46 +1100)]
properly quote the definition of warns
James E Keenan [Mon, 6 Jan 2020 20:14:10 +0000 (15:14 -0500)]
Russ Allbery [Mon, 6 Jan 2020 20:04:59 +0000 (15:04 -0500)]
Sync with CPAN version 5.00 of Term::ANSIColor
Committer: Provide additional email address for contributor.
Tony Cook [Sun, 24 Nov 2019 22:27:16 +0000 (09:27 +1100)]
error check the calls to sigaddset in POSIX::SigSet->new
Coverity complained that SvIV() could return negative numbers,
but doesn't complain about the similar call in the sigaddset()
method, which is error checked.
So error check sigaddset() and throw an error if it fails.
CID 244386.
Craig A. Berry [Sat, 4 Jan 2020 21:35:45 +0000 (15:35 -0600)]
Fix skip count in cachepropagate-tcp.t
A new test was added in a section that is skipped when neither
fork nor pseudo-fork is available, so the skip count needs to be
adjusted to match.
Karl Williamson [Sat, 28 Dec 2019 05:17:43 +0000 (22:17 -0700)]
utf8.c: Comment white-space only
Karl Williamson [Sat, 28 Dec 2019 05:17:10 +0000 (22:17 -0700)]
utf8.c: Use casts to silence some warnings
Karl Williamson [Sat, 28 Dec 2019 05:16:09 +0000 (22:16 -0700)]
utf8.c: Change internal variable's type
Packed warnings are 32 bit. This silences some compiler warnings.
Karl Williamson [Sat, 4 Jan 2020 04:37:08 +0000 (21:37 -0700)]
utf8.c: Change parameter types of internal fcns
These generated warnings on certain platform builds, and weren't the
best types for the purpose anyway.
Karl Williamson [Sat, 28 Dec 2019 04:55:54 +0000 (21:55 -0700)]
Change parameter type of static fcn
This makes the first parameter consistent with the other similar
parameter.
Karl Williamson [Fri, 27 Dec 2019 20:18:58 +0000 (13:18 -0700)]
Change some structures/fcns to use I32 and U32
This is because these deal with only legal Unicode code points, which
are restricted to 21 bits, so 16 is too few, but 32 is sufficient to
hold them. Doing this saves some space/memory on 64 bit builds where an
int is 64 bits.
Nicolas R [Fri, 3 Jan 2020 00:01:57 +0000 (17:01 -0700)]
Bump copyright to 2020 in perl.c and README.
check that porting/copyright.t is passing when
run with --now
../perl -I../lib porting/copyright.t --now
Dan Book [Tue, 9 Jul 2019 05:36:32 +0000 (01:36 -0400)]
recommend numeric comparisons for $]
Dan Book [Wed, 18 Dec 2019 21:55:48 +0000 (16:55 -0500)]
perlipc: strict safety, consistency, cleanup
* made all examples consistently strict-safe
* included 'use strict' and 'use warnings' in all "full" examples
* removed -w from shebangs (replaced by 'use warnings')
* removed inconsistent forward declaration of variables
* mention in IO::Handle comment that it's only needed before 5.14
* link to core modules IPC::Open2, IPC::Open3, and Socket
* add required waitpid to IPC::Open2 example
* removed unnecessary usage of English
* removed unnecessary usage of FileHandle
Karl Williamson [Thu, 2 Jan 2020 17:09:31 +0000 (10:09 -0700)]
Revert "Add some defensive coding to av_store()"
This reverts commit
bc62bf8519f9005df2fb29dbd3d330202b258b6b.
As Dave Mitchell said in <Perl/perl5/issues/17265/
570253376@github.com>
"The docs for av_store() say that the caller is responsible for first
incrementing the ref count of the new SV before passing it to
av_store(). In the normal case of the two elements being different,
av_store() will decrement the old SV before storing the new one, and
everything is good. When the two elements are the same SV, av_store()
*still* needs to decrement the ref count, to undo the increment the
caller just did."
This should resolve GH #17265
David Mitchell [Thu, 2 Jan 2020 14:00:23 +0000 (14:00 +0000)]
OP_MULTIDEREF: avoid trailing null aux byte
GH #17301
The aux array in an OP_MULTIDEREF op consists of an action word
containing as many actions as will fit shifted together, followed by
words containing the arguments for those actions. Then another action
word, and so on. The code in S_maybe_multideref() which creates those
ops was reserving a new slot in the aux array for a new action word when
the old one became full. If it then turned out that no more actions
were needed, this extra slot was harmlessly filled with a zero.
However it turns out that the B::UNOP_AUX::aux_list() introspection
method would, under those circumstances, claim to have returned one
more SV on the stack than it actually had, leading to SEGVs etc.
I could have fixed aux_list() directly to cope with an extra null word,
but instead I did the more general fix of ensuring that
S_maybe_multideref() never adds an extra null word in the first place.
The test added to ext/B/t/b.t fails before this commit; the new test
in lib/B/Deparse.t doesn't, but was added for completeness.
Nicolas R [Mon, 30 Dec 2019 23:10:36 +0000 (16:10 -0700)]
Encode: stop importing t/whatwg-aliases.t test
Do not import t/whatwg-aliases.t which is failing when
AUTHOR_TESTING is set.
Nicolas R [Mon, 30 Dec 2019 23:27:43 +0000 (16:27 -0700)]
Adjust smoke-information workflow
The smoke-information workflow was failing on Pull Request.
1/ need to pull from origin in order to know 'blead' (which
in most cases is going to be GITHUB_BASE_REF)
2/ stop using GITHUB_HEAD_REF and use HEAD instead.
Felipe Gasper [Fri, 27 Dec 2019 02:09:08 +0000 (21:09 -0500)]
add POD for PL_phase, including example
Slaven Rezic [Sun, 29 Dec 2019 23:01:24 +0000 (18:01 -0500)]
Update documentation for hash_seed()
Update $VERSION.
For: https://github.com/Perl/perl5/issues/17399
Karl Williamson [Thu, 26 Dec 2019 23:00:50 +0000 (16:00 -0700)]
PATCH: GH #17391 tr/// regression
This was the result of my not thinking through how things should work.
I added tests for the incorrect behavior. This commit modifies them, so
that there is no need for the test in the ticket.
Karl Williamson [Sun, 29 Dec 2019 03:00:53 +0000 (20:00 -0700)]
op.c: Fix typo in comment
Andy Dougherty [Wed, 28 Aug 2019 14:30:23 +0000 (10:30 -0400)]
Include <stdio.h> in getpgrp/setpgrp probes for printf prototype.
C compilers typically issue a warning, but c++ compilers may abort with
an error.
Andy Dougherty [Tue, 27 Aug 2019 19:22:05 +0000 (15:22 -0400)]
Fix strtoll, strtoul, and strtouq probes to compile under clang++.
The test programs were missing the stdlib.h header, and needed
tweaks to the check() prototype to compile under clang++. These
changes should be fine for C compilers as well, but they have typically
been more forgiving, so shouldn't be affected.
Andy Dougherty [Tue, 27 Aug 2019 19:00:26 +0000 (15:00 -0400)]
Fix strtoull() probe to run under clang++.
Include the appropriate header and get rid of slightly
incorrect prototype. Change function return type to void
since we don't explicitly return a useful value.
Andy Dougherty [Tue, 27 Aug 2019 16:58:23 +0000 (12:58 -0400)]
Use a compile and run test for lchown() to satisfy clang++.
For glibc, previous reports were that some functions (such as lchown())
are present in libc, but are unimplemented. That is, they always fail
and set errno=ENOSYS. Unfortunately, the stub test doesn't work under
clang++. Thus use a compile and run test. This should be more reliable.
Andy Dougherty [Tue, 27 Aug 2019 16:55:57 +0000 (12:55 -0400)]
Add <stdlib.h> for futimes compilation test.
Since the test uses exit(), the appropriate header should be
included. clang++ throws an error otherwise.
Karl Williamson [Sun, 29 Dec 2019 19:03:16 +0000 (12:03 -0700)]
POSIX.xs: Fix typo displayed when fcn doesn't exist
Karl Williamson [Sun, 29 Dec 2019 18:10:13 +0000 (11:10 -0700)]
op.c: Use %NVgf instead of %g format in debug stmt
The former is portable to different sized doubles.
James E Keenan [Tue, 12 Nov 2019 21:25:57 +0000 (16:25 -0500)]
Introduce EXAMPLES section of documentation
Provide contextualized invocations of 'Porting/bisect.pl', e.g.:
* What was the problem for which we were bisecting?
* What, if anything, did we do prior to bisecting?
* What is the bug ticket for this problem?
Examples:
* Bisection with target 'miniperl'
* Bisecting failure on threaded builds only
* Example for '--crash' switch
* Failure of 'make' to complete build with specific C-compiler
Bernhard M. Wiedemann [Mon, 23 Dec 2019 20:15:03 +0000 (21:15 +0100)]
Document that epoch is always 1970
and not meant to be interpreted as 2070 because of rolling century.
Fixes GH issue 16431
Bernhard M. Wiedemann is now a Perl author.
Karl Williamson [Fri, 27 Dec 2019 18:40:46 +0000 (11:40 -0700)]
regcomp.c: Use marker for non-user properties
A marker is created for a property that could be both a user-defined
one, and an official Unicode one. The expansion of these is deferred
until runtime, in case the sub that implements a user-defined property
wasn't known at the time of the pattern compilation. If at runtime,
there still isn't the proper sub, the property is looked up as
potentially an official Unicode one.
But I forgot to check the marker, which is set only if there is a
potential ambiguity. If the marker isn't set, there is no need to try
to look it up as an official Unicode property. I couldn't think of a
test where this fails, but at least it saves effort.
Karl Williamson [Fri, 27 Dec 2019 18:20:08 +0000 (11:20 -0700)]
PATCH: GH #17384 out of bounds read in qr//
This turned out to be because there are two versions of the property
name being parsed: 1) the original input; and 2) a canonicalized one
with characters squeeezed out that are usually optional, such as spaces,
dashes and, here, underscores.
The code was conflating the two names, and moving along the squeezed
name based on counts from the unsqueezed one, hence going too far in the
buffer.
Karl Williamson [Wed, 25 Dec 2019 08:37:37 +0000 (01:37 -0700)]
regcomp.c: Change names of 2 macros
This is in preparation for the next commit, reflecting their new purpose
Karl Williamson [Sat, 14 Dec 2019 20:26:36 +0000 (13:26 -0700)]
t/test.pl: Fix to display properly on EBCDIC
This was more complicated than it need be for modern perls.
Devel::PPPort has a version that works with older ones.
And it didn't work properly on EBCDIC, thinking printables weren't, and
vice versa.
Karl Williamson [Thu, 26 Dec 2019 21:54:37 +0000 (14:54 -0700)]
win32/vdir.h: Rmv extraneous line
introduced by
9c35352692462eae5f6e2078f2ee69870a9042a2
Karl Williamson [Sun, 22 Dec 2019 01:51:38 +0000 (18:51 -0700)]
PATCH: GH #17381 netbsd static assert failure
As discussed in the ticket, static assertions aren't always enabled
here. The solution is to use our already-existing fallback to emulate
static assertions in more instances as suggested in the ticket.
Karl Williamson [Sun, 8 Dec 2019 16:20:55 +0000 (09:20 -0700)]
utf8.c: Use inRANGE
It is clearer and faster
Karl Williamson [Fri, 6 Sep 2019 16:25:26 +0000 (10:25 -0600)]
doio.c: Use inRANGE macro
Karl Williamson [Wed, 2 Oct 2019 04:34:25 +0000 (22:34 -0600)]
util.c: Use inRANGE macro
Karl Williamson [Thu, 3 Oct 2019 03:10:36 +0000 (21:10 -0600)]
pp_pack.c: Use inRANGE macro
which is more efficient
Karl Williamson [Thu, 3 Oct 2019 03:02:44 +0000 (21:02 -0600)]
win32/vdir.h: Use inRANGE macro
which is more efficient.
Karl Williamson [Thu, 3 Oct 2019 03:02:01 +0000 (21:02 -0600)]
win32/win32.c: Use inRANGE macro
which is more efficient.