This is a live mirror of the Perl 5 development currently hosted at
5 months agoperl5335delta grammar nit
Dan Book [Sun, 20 Dec 2020 17:24:24 +0000 (12:24 -0500)]
perl5335delta grammar nit

5 months agoperlapi: SvPVbyte_force() and kin: clarify.
Karl Williamson [Sun, 20 Dec 2020 16:52:10 +0000 (09:52 -0700)]
perlapi: SvPVbyte_force() and kin: clarify.

5 months agoperlapi: Document newSVsv_flags
Karl Williamson [Sun, 20 Dec 2020 16:43:06 +0000 (09:43 -0700)]
perlapi: Document newSVsv_flags

5 months agoembed.fnc: Mark several do_dump fcns as Core only
Karl Williamson [Wed, 22 Jul 2020 12:31:56 +0000 (06:31 -0600)]
embed.fnc: Mark several do_dump fcns as Core only

These appear to be helper functions for various API functions; there are
no uses of them in cpan

5 months agoembed.fnc: Mark sv_2uv, etc. as Core only
Karl Williamson [Wed, 22 Jul 2020 12:25:44 +0000 (06:25 -0600)]
embed.fnc: Mark sv_2uv, etc. as Core only

There are documented macros that one is supposed to use instead for this

5 months agoembed.fnc: Mark stack_grow as Core only
Karl Williamson [Wed, 22 Jul 2020 12:23:16 +0000 (06:23 -0600)]
embed.fnc: Mark stack_grow as Core only

This is a helper function used by such things as SSGROW; there is no
cpan usage

5 months agoembed.fnc: Mark scan_num as Core only
Karl Williamson [Wed, 22 Jul 2020 12:19:36 +0000 (06:19 -0600)]
embed.fnc: Mark scan_num as Core only

This is used by the toker to scan a number; there is no cpan usage

5 months agoembed.fnc: Mark cx_dump as Core only
Karl Williamson [Wed, 22 Jul 2020 12:16:28 +0000 (06:16 -0600)]
embed.fnc: Mark cx_dump as Core only

This appears to be for internal debugging; there is no cpan usage

5 months agoembed.fnc: Mark av_arylen_p, av_iter_p as Core only
Karl Williamson [Wed, 22 Jul 2020 12:07:30 +0000 (06:07 -0600)]
embed.fnc: Mark av_arylen_p, av_iter_p as Core only

These appear to be internal functions, and there is no cpan usage

The macro GIMME_V is what one is supposed to use for this functionality.

5 months agoembed.fnc: Mark doing_taint as Core only
Karl Williamson [Wed, 22 Jul 2020 12:02:56 +0000 (06:02 -0600)]
embed.fnc: Mark doing_taint as Core only

This appears to be for internal use, and there are no cpan usages

5 months agoembed.fnc: Mark cxinc as Core only
Karl Williamson [Wed, 22 Jul 2020 11:48:53 +0000 (05:48 -0600)]
embed.fnc: Mark cxinc as Core only

The macro CXINC is what one is supposed to use for this functionality.
(though it is currently undocumented)

5 months agoembed.fnc: Mark moreswitches as Core only
Karl Williamson [Wed, 22 Jul 2020 11:46:35 +0000 (05:46 -0600)]
embed.fnc: Mark moreswitches as Core only

This is an internal function used to parse command line options; there
are no cpan uses.

5 months agoembed.fnc: Mark runops_debug, runops_standard as Core only
Karl Williamson [Wed, 22 Jul 2020 11:38:37 +0000 (05:38 -0600)]
embed.fnc: Mark runops_debug, runops_standard as Core only

These are internal functions to run the program; there are no cpan uses

5 months agoembed.fnc: Mark regnext as Core only
Karl Williamson [Wed, 22 Jul 2020 11:29:01 +0000 (05:29 -0600)]
embed.fnc: Mark regnext as Core only

This is used internally by the regex engine; there is one use in cpan,
an internals module, Devel::RegExp by Ilya Zakharevich, with nothing
dependent on it, and last updated in 1995.

5 months agoembed.fnc: Mark cx_dup as Core only
Karl Williamson [Wed, 22 Jul 2020 11:19:41 +0000 (05:19 -0600)]
embed.fnc: Mark cx_dup as Core only

Similar cx functions are supposed to be called with a macro for their
functionality, but no such macro exists for this, and there are no uses

5 months agoperlapi: Document and consolidate SvPV functions
Karl Williamson [Mon, 14 Dec 2020 02:41:24 +0000 (19:41 -0700)]
perlapi: Document and consolidate SvPV functions

5 months agoPOSIX::asctime pod: Note it always returns English
Karl Williamson [Mon, 14 Dec 2020 15:51:45 +0000 (08:51 -0700)]
POSIX::asctime pod: Note it always returns English

And give locale's alternative

5 months agoperlfunc: Improve localtime entry
Karl Williamson [Mon, 14 Dec 2020 02:07:54 +0000 (19:07 -0700)]
perlfunc: Improve localtime entry

This rearranges some paragraphs that really belong together, and
clarifies the result is always in English

5 months agoregexec.c: Link to github issue in comment
Karl Williamson [Sun, 20 Dec 2020 13:28:38 +0000 (06:28 -0700)]
regexec.c: Link to github issue in comment

5 months agoPrepare Module::CoreList for 5.33.6
Max Maischein [Sun, 20 Dec 2020 14:44:10 +0000 (15:44 +0100)]
Prepare Module::CoreList for 5.33.6

5 months agoBump version to 5.33.6
Max Maischein [Sun, 20 Dec 2020 14:32:28 +0000 (15:32 +0100)]
Bump version to 5.33.6

5 months agonew perldelta for 5.33.6
Max Maischein [Sun, 20 Dec 2020 14:28:55 +0000 (15:28 +0100)]
new perldelta for 5.33.6

5 months agoUpdate release schedule
Max Maischein [Sun, 20 Dec 2020 14:23:02 +0000 (15:23 +0100)]
Update release schedule

5 months agoUpdate epigraphs.pod with quote from Max Weber
Max Maischein [Sun, 20 Dec 2020 14:22:54 +0000 (15:22 +0100)]
Update epigraphs.pod with quote from Max Weber

5 months agoMerge branch 'release-5.33.5' into blead
Max Maischein [Sun, 20 Dec 2020 14:12:21 +0000 (15:12 +0100)]
Merge branch 'release-5.33.5' into blead

# Conflicts:
# pod/perldelta.pod

5 months agoadd new release to perlhist v5.33.5
Max Maischein [Sun, 20 Dec 2020 10:19:16 +0000 (11:19 +0100)]
add new release to perlhist

5 months agoUpdate Module::CoreList for 5.33.5
Max Maischein [Sun, 20 Dec 2020 09:53:09 +0000 (10:53 +0100)]
Update Module::CoreList for 5.33.5

5 months agoFinalize perldelta for 5.33.5
Max Maischein [Sun, 20 Dec 2020 09:45:48 +0000 (10:45 +0100)]
Finalize perldelta for 5.33.5

5 months agoFinalise perldelta for 5.33.5
Max Maischein [Sun, 20 Dec 2020 09:32:01 +0000 (10:32 +0100)]
Finalise perldelta for 5.33.5

5 months agoFix broken PERL_MEM_LOG under threads
Karl Williamson [Sun, 6 Dec 2020 22:01:14 +0000 (15:01 -0700)]
Fix broken PERL_MEM_LOG under threads

This fixes GH #18341

There are problems with getenv() on threaded perls wchich can lead to
incorrect results when compiled with PERL_MEM_LOG.

Commit 0b83dfe6dd9b0bda197566adec923f16b9a693cd fixed this for some
platforms, but as Tony Cook, pointed out there may be
standards-compliant platforms that that didn't fix.

The detailed comments outline the issues and (complicated) full solution.

5 months agoAdd GETENV_LOCK
Karl Williamson [Tue, 1 Dec 2020 14:44:18 +0000 (07:44 -0700)]

get_env() needs to lock other threads from writing to the environment
while it is executing.  It may need to have an exclusive lock if those
threads can clobber its buffer before it gets a chance to save them.
The previous commit has added a Configure probe which tells us if that
is the case.  This commit uses it to select which type of mutex to use.

5 months agoAdd Configure probe for getenv() buffer race
Karl Williamson [Sat, 28 Nov 2020 16:20:46 +0000 (09:20 -0700)]
Add Configure probe for getenv() buffer race

Most implementations do not have a problem with two getenv()'s running
simultaneously in different threads.  But Posix doesn't require such
good behavior.  This adds a simple probe to test the current system.

5 months agoperl.h: Add capability for many-reader ENV mutex locking
Karl Williamson [Tue, 1 Dec 2020 14:17:21 +0000 (07:17 -0700)]
perl.h: Add capability for many-reader ENV mutex locking

There are several places where there could be a problem in the
environment were changed by another thread when a function is executing,
but otherwise if another thread were reading the environment at the same
time, there isn't a problem.  This adds mutex for that situation.
Future commits will take advantage of it.

5 months agoMake many-reader mutexes more resilient
Karl Williamson [Wed, 9 Dec 2020 01:30:56 +0000 (18:30 -0700)]
Make many-reader mutexes more resilient

These mutexes rely on a counter being accurate to work.  If for some
reason that I can't imagine happening, the count goes below 0, this
commit resets it to zero, which may be enough to cause the program to

5 months agoregexec.c: White-space, comments only
Karl Williamson [Sat, 14 Nov 2020 20:55:38 +0000 (13:55 -0700)]
regexec.c: White-space, comments only

Mostly indent because the prior commit created a new block

5 months agoregexec.c: Revamp S_setup_EXACTISH_ST() loop end conditions
Karl Williamson [Fri, 13 Nov 2020 16:38:21 +0000 (09:38 -0700)]
regexec.c: Revamp S_setup_EXACTISH_ST() loop end conditions

Consider the pattern /A*B/ where A and B are arbitrary.  The pattern
matching code tries to make a tight loop to match the span of A's.  The
logic of this was not really updated when UTF-8 was added.  I did
revamp it some releases ago to fix some bugs and to at least consider

This commit changes it so that Unicode is now a first class citizen.
Some details are listed in the ticket GH #18414

5 months agoregexec.c: Change name of static function
Karl Williamson [Sun, 18 Oct 2020 16:51:22 +0000 (10:51 -0600)]
regexec.c: Change name of static function

The new name reflects its new functionality coming in future commits

5 months agoregexec.c: Trim trailing blanks
Karl Williamson [Sun, 18 Oct 2020 16:46:14 +0000 (10:46 -0600)]
regexec.c: Trim trailing blanks

5 months Get code point folding to a seq
Karl Williamson [Sun, 18 Oct 2020 16:20:38 +0000 (10:20 -0600)] Get code point folding to a seq

Previously could tell if an input string was a
multi-character fold of some Unicode code point.  This commit adds the
ability to return what that code point is.  This capability will be used
in a later commit.

5 months agoregen/ Rmv special case
Karl Williamson [Wed, 11 Nov 2020 23:37:23 +0000 (16:37 -0700)]
regen/ Rmv special case

This avoided checking for optimizations.  Whatever its original use, it
doesn't do any good, and the optimizations are actually useful.

5 months agoext/POSIX/t/waitpid.t: Correct one typo
James E Keenan [Sat, 19 Dec 2020 20:41:56 +0000 (15:41 -0500)]
ext/POSIX/t/waitpid.t: Correct one typo

5 months agoMANIFEST: Add ext/POSIX/t/iv_const.t
TAKAI Kousuke [Fri, 18 Dec 2020 09:55:50 +0000 (18:55 +0900)]
MANIFEST: Add ext/POSIX/t/iv_const.t

5 months agoext/POSIX: Added tests to check integer constants are defined as IV
TAKAI Kousuke [Thu, 17 Dec 2020 14:27:31 +0000 (23:27 +0900)]
ext/POSIX: Added tests to check integer constants are defined as IV

5 months agoext/POSIX: Change integer constants to IV.
TAKAI Kousuke [Wed, 16 Dec 2020 17:17:31 +0000 (02:17 +0900)]
ext/POSIX: Change integer constants to IV.

Some floating-point related constants, such as (FLT|L?DBL)_DIG,
FLT_RADIX, FP_*, etc. had been defined as NV, but these are
actually integer constants.

This change should not affect the behaviour of user programs.

5 months agoperldelta for edd16cfcff
James E Keenan [Sat, 19 Dec 2020 17:42:48 +0000 (17:42 +0000)]
perldelta for edd16cfcff

5 months agoAdd pod/perldocstyle.pod 18412/head
Jason McIntosh [Sat, 19 Dec 2020 14:37:40 +0000 (14:37 +0000)]
Add pod/perldocstyle.pod


Committer: Adding a new file underneath pod/ entails adding (i) an entry for that file
in pod/perl.pod and (ii) entries in win32/pod.mak.

(i) In turn requires, figuring out an appropriate category within
perl.pod in which to place the new file.  The entry should match that in
MANIFEST and be consistent with the style of entries in MANIFEST.

(ii) Requires running Porting/ so that entries in
win32/pod.mak are also generated for the corresponding *.man, *.html and
*.tex files.


5 months agoUpdate Config::Perl::V to 0.33
H.Merijn Brand [Fri, 18 Dec 2020 15:41:30 +0000 (16:41 +0100)]
Update Config::Perl::V to 0.33

5 months agoMerge branch 'thibaultduponchelle-fix_rt_number_in_perl5260delta' into blead
James E Keenan [Fri, 18 Dec 2020 14:21:37 +0000 (09:21 -0500)]
Merge branch 'thibaultduponchelle-fix_rt_number_in_perl5260delta' into blead

5 months agoMerge branch 'fix_rt_number_in_perl5260delta' of
James E Keenan [Fri, 18 Dec 2020 14:20:42 +0000 (09:20 -0500)]
Merge branch 'fix_rt_number_in_perl5260delta' of into thibaultduponchelle-fix_rt_number_in_perl5260delta

5 months agoFix RT number in perl5260delta.pod 18411/head
Thibault DUPONCHELLE [Fri, 18 Dec 2020 13:27:53 +0000 (14:27 +0100)]
Fix RT number in perl5260delta.pod

5 months agoUpdate ExtUtils-Install to CPAN version 2.20
Chris 'BinGOs' Williams [Fri, 18 Dec 2020 12:54:10 +0000 (12:54 +0000)]
Update ExtUtils-Install to CPAN version 2.20



- Exercise _is_prefix() method more in tests
- Optimisations for file comparisons
- Optimisations for directory creation
- Typo fix in POD
- Optimisations for tree traversal

5 months agoAlso update with the updated PerlIO::via::QuotedPrint version
Max Maischein [Fri, 18 Dec 2020 09:44:02 +0000 (10:44 +0100)]
Also update with the updated PerlIO::via::QuotedPrint version

5 months agoUpdate PerlIO::via::QuotedPrint from 0.08 to 0.09
Max Maischein [Fri, 18 Dec 2020 09:40:09 +0000 (10:40 +0100)]
Update PerlIO::via::QuotedPrint from 0.08 to 0.09

This should be picked up by the auto-generated perldelta

5 months agoUpdate Text::Balanced from 2.03 to 2.04
Max Maischein [Fri, 18 Dec 2020 09:12:49 +0000 (10:12 +0100)]
Update Text::Balanced from 2.03 to 2.04

No entry in Perldelta because that will be generated automatically

5 months agoCorrectly set LC_CTYPE back in POSIX/t/time.t
Leon Timmermans [Thu, 17 Dec 2020 20:02:46 +0000 (21:02 +0100)]
Correctly set LC_CTYPE back in POSIX/t/time.t

5 months agot/lib/croak/toke: Correct test label
James E Keenan [Tue, 15 Dec 2020 16:38:30 +0000 (11:38 -0500)]
t/lib/croak/toke: Correct test label

The RT ticket number cited in the test's label is wrong.  The body of
the commit message for commit 7259f4194f3131957240f6b3dba47b74f53ac660
shows the correct RT number.  Provide GH number as well.

5 months Adjust max permissible line length
Karl Williamson [Mon, 14 Dec 2020 20:38:47 +0000 (13:38 -0700)] Adjust max permissible line length

perldoc takes up 4 column indent, not 7.

5 months agopodcheck.t: Combine duplicated code into a sub
Karl Williamson [Mon, 14 Dec 2020 20:33:37 +0000 (13:33 -0700)]
podcheck.t: Combine duplicated code into a sub

5 months agopodcheck.t: perldoc standard indent is 4.
Karl Williamson [Mon, 14 Dec 2020 20:29:19 +0000 (13:29 -0700)]
podcheck.t: perldoc standard indent is 4.

Before, it was using an expected nroff indent of 7.  But current perldoc
places the =head1 lines at the left margin, and the text within them
indented by 4.

5 months agoperlapi: 'ie' should be 'i.e.', and italicized
Karl Williamson [Mon, 14 Dec 2020 20:41:07 +0000 (13:41 -0700)]
perlapi: 'ie' should be 'i.e.', and italicized

5 months agobump $XS::APItest::VERSION
Tony Cook [Mon, 14 Dec 2020 05:00:33 +0000 (16:00 +1100)]
bump $XS::APItest::VERSION

5 months agoconsistently parenthesise the RW lock macro arguments
Tony Cook [Mon, 14 Dec 2020 04:54:25 +0000 (15:54 +1100)]
consistently parenthesise the RW lock macro arguments

and fix the mixed up pointer vs non-pointer use of the mutex

Without the parentheses (or without the new tests in the previous
commit) for code like;


the MUTEX_LOCK(mutex.lock) in that code would expand to:


and happen to work,  even though the next line has:

  if ((mutex)->readers_count)

treating the mutex parameter as a pointer.

With the parentheses the MUTEX_LOCK(mutex.lock) becomes:


which as expected fails to compile in a similar way to the pointer
test code in the previous commit.

5 months agobuild test for the read/write mutex macros
Tony Cook [Mon, 14 Dec 2020 04:20:17 +0000 (15:20 +1100)]
build test for the read/write mutex macros

This fails to compile

5 months agoperl.h: White-space only
Karl Williamson [Thu, 27 Aug 2020 13:47:02 +0000 (07:47 -0600)]
perl.h: White-space only

Properly indent some nested #defines

5 months agoperlapi: Remove duplicate text
Karl Williamson [Sun, 6 Sep 2020 16:55:28 +0000 (10:55 -0600)]
perlapi: Remove duplicate text

This came about in a rebasing error

5 months agoDocument and consolidate SvPV..force functions
Karl Williamson [Mon, 14 Sep 2020 16:21:49 +0000 (10:21 -0600)]
Document and consolidate SvPV..force functions

5 months agoConsolidate and document all get_cvFOO() variants
Karl Williamson [Wed, 22 Jul 2020 22:47:53 +0000 (16:47 -0600)]
Consolidate and document all get_cvFOO() variants

6 months agomany-reader mutexes: Change structure element name
Karl Williamson [Thu, 10 Dec 2020 17:11:34 +0000 (10:11 -0700)]
many-reader mutexes: Change structure element name

The old name did not encompass all the possible reasons for the
mutex signal condition to be invoked

6 months agoPERL_WRITE_UNLOCK: add missing condition signal
Karl Williamson [Thu, 10 Dec 2020 18:07:15 +0000 (11:07 -0700)]
PERL_WRITE_UNLOCK: add missing condition signal

The mutex is locked, and any contenders are awaiting a signal, which
until this commit was missing.

6 months agodist/threads/t/libc.t: Add timer to avoid deadlock
Karl Williamson [Thu, 10 Dec 2020 15:58:53 +0000 (08:58 -0700)]
dist/threads/t/libc.t: Add timer to avoid deadlock

This test file can deadlock if there are bugs.  Add a timeout to keep
the test from hanging indefinitely.

6 months agolocale.c: Work around a z/OS limitation/feature
Karl Williamson [Fri, 11 Dec 2020 21:59:28 +0000 (14:59 -0700)]
locale.c: Work around a z/OS limitation/feature

Without per-thread locales, a multi-thread application is inherently
unsafe.  IBM solves that by allowing you to set up the locale any way
you want, but after you've created a thread, all future locale changes
are ignored, and return failure.

But Perl itself changes the locale in a couple of cases.  Recent changes
have surfaced this issue in one case, leading to a panic.  And this
commit works around it, so that messages will be displayed in the locale
in effect before the threads were created.

The remaining case requires further investigation.  Nothing in our suite
is failing.

6 months agoperlapi: Add markup
Karl Williamson [Thu, 10 Dec 2020 23:09:31 +0000 (16:09 -0700)]
perlapi: Add markup

6 months agoCombine the two separate smoke test sections
Tom Hukins [Wed, 2 Dec 2020 20:01:58 +0000 (20:01 +0000)]
Combine the two separate smoke test sections

6 months agoSimplify the release management instructions
Tom Hukins [Tue, 17 Nov 2020 16:43:29 +0000 (16:43 +0000)]
Simplify the release management instructions

Getting access to GitHub issues and commit privileges takes one action,
not two, so merge the separate sections.

6 months agodromedary no longer has a public_html directory
Tom Hukins [Tue, 17 Nov 2020 13:58:40 +0000 (13:58 +0000)]
dromedary no longer has a public_html directory

The old machine has been offline for some time.
A replacement exists at, but this does not provide
per-user public_html directories for sharing files.

6 months agoSynch with CPAN distribution libnet-3.12
Steve Hay [Thu, 10 Dec 2020 14:15:51 +0000 (09:15 -0500)]
Synch with CPAN distribution libnet-3.12

6 months agoCorrect POD formatting error
James E Keenan [Thu, 10 Dec 2020 14:01:03 +0000 (09:01 -0500)]
Correct POD formatting error

6 months agoImplement SAVEt_STRLEN_SMALL
Paul "LeoNerd" Evans [Sat, 27 Jun 2020 17:10:47 +0000 (18:10 +0100)]

Most uses of SAVEt_STRLEN actually store small values; often zero.
Rather than using an entire U64-sized element for these values, it saves
space to use the same "SMALL" mechanism as other numerical values, like

6 months agoFix freebsd/netbsd builds
Karl Williamson [Wed, 9 Dec 2020 00:09:04 +0000 (17:09 -0700)]
Fix freebsd/netbsd builds

These have an inconsistent configuration in which several functions exist
for thread-safe locales, but the crucial one doesn't show up in our
Configure probe.  The code this commit fixes assumed that all or nothing
would be present.

6 months agoFix cygwin build
Karl Williamson [Wed, 9 Dec 2020 00:07:17 +0000 (17:07 -0700)]
Fix cygwin build

A macro name changed, and I didn't see it in the grep

6 months agobump's $VERSION
Tony Cook [Tue, 8 Dec 2020 23:43:12 +0000 (10:43 +1100)]
bump's $VERSION

6 months agojkahrman is now a perl author
Tony Cook [Tue, 8 Dec 2020 23:42:59 +0000 (10:42 +1100)]
jkahrman is now a perl author

6 months agotest - and . at beginning of debugger alias name
Tony Cook [Tue, 8 Dec 2020 23:19:26 +0000 (10:19 +1100)]
test - and . at beginning of debugger alias name

6 months agoAllow debugger aliases that start with '-' and '.'
jkahrman [Thu, 16 Apr 2020 06:00:04 +0000 (02:00 -0400)]
Allow debugger aliases that start with '-' and '.'

Since the '.' and '-' commands don't take any arguments and don't run if any are provided, don't treat commands starting with these characters as the single commands '.' and '-'. Restores behavior that existed prior to (v5.27) at least back to v5.8.8

6 months agolocale.c: Remove some unnecessary mutex locks
Karl Williamson [Tue, 8 Dec 2020 20:25:36 +0000 (13:25 -0700)]
locale.c: Remove some unnecessary mutex locks

These aren't necessary as the called function has its own lock until
done copying into the local structure.

And these were breaking blead on Windows, as they are no longer defined.
The smoke I ran included more commits beyond the breaking one, so I
didn't catch it.

6 months agolocale.c: Unlock mutex before croaking
Karl Williamson [Sun, 6 Dec 2020 23:29:11 +0000 (16:29 -0700)]
locale.c: Unlock mutex before croaking

These cases aren't supposed to happen, but unlock the mutex first;
we could get into deadlock in trying to output the death message.

6 months agoName individual locale locks
Karl Williamson [Mon, 30 Nov 2020 17:11:01 +0000 (10:11 -0700)]
Name individual locale locks

These locks for different functions all use the same underlying mutex;
but that may not always be the case.  By creating separate names
used only when we think they will be necessary, the compiler will
complain if the conditions in the code that actually use them are the
same.  Doing this showed a misspelling in an #ifdef, fixed in

6 months agoRefactor locale mutex setup
Karl Williamson [Mon, 30 Nov 2020 16:46:34 +0000 (09:46 -0700)]
Refactor locale mutex setup

This was prompted by my realization that even on a locale thread-safe
platform, there are functions we call that may not be thread-safe in
that they return their results in an internal static buffer, which may
be process-wide instead of per-thread.  Tomasz Konojacki++ briefly
looked at Windows source code for localeconv() and this indeed did
appear to be the case.

If we thought a platform was thread-safe, no locale mutexes were set up,
and instead the calls in the code to lock were no-oops.  This would lead
to potential races, the most likely candidate being localeconv().  None
have been reported, at least as far as we know.  Likely that function
isn't called frequently.  This would be true on both Posix 2008 and
Windows platforms, except possibly for FreeBSD, which may be the only
platform that we support that has a localeconv_l() function, which is
supposed to be immune from this issue..

The solution adopted here is to test for all the possible functions that
the Perl core uses that may be susceptible to this, and to set up the
mutex if any are found.  Thus there won't be no-ops where there should
be a lock.

6 months agoChange name of mutex macro.
Karl Williamson [Mon, 30 Nov 2020 00:05:13 +0000 (17:05 -0700)]
Change name of mutex macro.

This macro is for localeconv(); the new name is clearer as to the
meaning, and this preps for further changes.

6 months agolocale.c: Add debugging info to panic message
Karl Williamson [Sun, 6 Dec 2020 22:45:20 +0000 (15:45 -0700)]
locale.c: Add debugging info to panic message

6 months agoduplocale() is part of Posix 2008 locales
Karl Williamson [Sun, 6 Dec 2020 22:43:45 +0000 (15:43 -0700)]
duplocale() is part of Posix 2008 locales

Thus if we know we have the Posix versions, we have duplocale(), and
hence don't need to test separately for it.

6 months agoFix up many-reader mutex typedef
Karl Williamson [Sun, 6 Dec 2020 22:16:41 +0000 (15:16 -0700)]
Fix up many-reader mutex typedef

This previously worked on some compilers, but not others.

6 months agoAdd author name in alphabetically correct place
Jae Bradley [Sat, 5 Dec 2020 20:57:16 +0000 (15:57 -0500)]
Add author name in alphabetically correct place

6 months agoUpdate the Xcode version in the testsuite.yml workflow
Jae Bradley [Wed, 2 Dec 2020 00:35:30 +0000 (19:35 -0500)]
Update the Xcode version in the testsuite.yml workflow

Xcode v12 is now the default Xcode version:

6 months agoUse macOS-10.15 explicitly
Jae Bradley [Tue, 1 Dec 2020 23:48:55 +0000 (18:48 -0500)]
Use macOS-10.15 explicitly

6 months agoAdd Jae Bradley as an Author
Jae Bradley [Tue, 1 Dec 2020 23:40:12 +0000 (18:40 -0500)]
Add Jae Bradley as an Author

6 months agoExplicitly use Catalina when running the test with Xcode 11
Jae Bradley [Tue, 1 Dec 2020 20:04:51 +0000 (15:04 -0500)]
Explicitly use Catalina when running the test with Xcode 11

6 months agoRemove empty "#ifdef"s
Tom Hukins [Wed, 2 Dec 2020 17:00:09 +0000 (17:00 +0000)]
Remove empty "#ifdef"s

6 months agoHere be camels
Chris 'BinGOs' Williams [Tue, 8 Dec 2020 11:58:44 +0000 (11:58 +0000)]
Here be camels

6 months agoperly.y: avoid <0 test on unsigned value
David Mitchell [Tue, 8 Dec 2020 09:50:47 +0000 (09:50 +0000)]
perly.y: avoid <0 test on unsigned value

Coverity CID 313707

Moving to a newer version of Bison has changed how the YYTRANSLATE()
macro is defined: in particular it now has a <0 test, which
Coverity is complaining about, since the arg is an unsigned value.

This commit just casts the arg back to a signed value. In more detail:
we formerly had:

    yytoken = YYTRANSLATE(NATIVE_TO_UNI(parser->yychar));

yychar is of type int, but NATIVE_TO_UNI returns a UV. So just cast the
result back to an int:

    yytoken = YYTRANSLATE((int)NATIVE_TO_UNI(parser->yychar));