3f1b01
From cac138107138a9814b32c4de74426225628f1646 Mon Sep 17 00:00:00 2001
3f1b01
From: Karl Williamson <khw@cpan.org>
3f1b01
Date: Sun, 17 Jan 2021 21:45:20 -0700
3f1b01
Subject: [PATCH] Add missing entries to perldiag; GH #18276
3f1b01
MIME-Version: 1.0
3f1b01
Content-Type: text/plain; charset=UTF-8
3f1b01
Content-Transfer-Encoding: 8bit
3f1b01
3f1b01
The ticket mentions yet another message, not addressed in this
3f1b01
commit, "Insecure private-use override".  That message is part of a
3f1b01
hook for a so-far unimplemented module, so it actually doesn't ever get
3f1b01
raised.
3f1b01
3f1b01
Committer: One correction per Grinnz comment in
3f1b01
https://github.com/Perl/perl5/pull/18491
3f1b01
Signed-off-by: Petr Písař <ppisar@redhat.com>
3f1b01
---
3f1b01
 pod/perldiag.pod | 45 +++++++++++++++++++++++++++++++++++++++++++++
3f1b01
 1 file changed, 45 insertions(+)
3f1b01
3f1b01
diff --git a/pod/perldiag.pod b/pod/perldiag.pod
3f1b01
index 9c91630d39..63f57f220e 100644
3f1b01
--- a/pod/perldiag.pod
3f1b01
+++ b/pod/perldiag.pod
3f1b01
@@ -2195,6 +2195,20 @@ single form when it must operate on them directly.  Either you've passed
3f1b01
 an invalid file specification to Perl, or you've found a case the
3f1b01
 conversion routines don't handle.  Drat.
3f1b01
 
3f1b01
+=item Error %s in expansion of %s
3f1b01
+
3f1b01
+(F) An error was encountered in handling a user-defined property
3f1b01
+(L<perlunicode/User-Defined Character Properties>).  These are
3f1b01
+programmer written subroutines, hence subject to errors that may
3f1b01
+prevent them from compiling or running.  The calls to these subs are
3f1b01
+C<eval>'d, and if there is a failure, this message is raised, using the
3f1b01
+contents of C<$@> from the failed C<eval>.
3f1b01
+
3f1b01
+Another possibility is that tainted data was encountered somewhere in
3f1b01
+the chain of expanding the property.  If so, the message wording will
3f1b01
+indicate that this is the problem.  See L
3f1b01
+property %s>.
3f1b01
+
3f1b01
 =item Eval-group in insecure regular expression
3f1b01
 
3f1b01
 (F) Perl detected tainted data when trying to compile a regular
3f1b01
@@ -2836,6 +2850,16 @@ not match 8 spaces.
3f1b01
 text.  You should check the pattern to ensure that recursive patterns
3f1b01
 either consume text or fail.
3f1b01
 
3f1b01
+=item Infinite recursion in user-defined property
3f1b01
+
3f1b01
+(F) A user-defined property (L
3f1b01
+Properties>) can depend on the definitions of other user-defined
3f1b01
+properties.  If the chain of dependencies leads back to this property,
3f1b01
+infinite recursion would occur, were it not for the check that raised
3f1b01
+this error.
3f1b01
+
3f1b01
+Restructure your property definitions to avoid this.
3f1b01
+
3f1b01
 =item Infinite recursion via empty pattern
3f1b01
 
3f1b01
 (F) You tried to use the empty pattern inside of a regex code block,
3f1b01
@@ -6273,6 +6297,20 @@ lexicals that are initialized only once (see L<feature>):
3f1b01
 This use of C<my()> in a false conditional was deprecated beginning in
3f1b01
 Perl 5.10 and became a fatal error in Perl 5.30.
3f1b01
 
3f1b01
+=item Timeout waiting for another thread to define \p{%s}
3f1b01
+
3f1b01
+(F) The first time a user-defined property
3f1b01
+(L<perlunicode/User-Defined Character Properties>) is used, its
3f1b01
+definition is looked up and converted into an internal form for more
3f1b01
+efficient handling in subsequent uses.  There could be a race if two or
3f1b01
+more threads tried to do this processing nearly simultaneously.
3f1b01
+Instead, a critical section is created around this task, locking out all
3f1b01
+but one thread from doing it.  This message indicates that the thread
3f1b01
+that is doing the conversion is taking an unexpectedly long time.  The
3f1b01
+timeout exists solely to prevent deadlock; it's long enough that the
3f1b01
+system was likely thrashing and about to crash.  There is no real remedy but
3f1b01
+rebooting.
3f1b01
+
3f1b01
 =item times not implemented
3f1b01
 
3f1b01
 (F) Your version of the C library apparently doesn't do times().  I
3f1b01
@@ -6846,6 +6884,13 @@ for the list of known options.
3f1b01
 L<perlrun|perlrun/-C [numberE<sol>list]> documentation of the C<-C> switch
3f1b01
 for the list of known options.
3f1b01
 
3f1b01
+=item Unknown user-defined property name \p{%s}
3f1b01
+
3f1b01
+(F) You specified to use a property within the C<\p{...}> which was a
3f1b01
+syntactically valid user-defined property, but no definition was found
3f1b01
+for it by the time one was required to proceed.  Check your spelling.
3f1b01
+See L<perlunicode/User-Defined Character Properties>.
3f1b01
+
3f1b01
 =item Unknown verb pattern '%s' in regex; marked by S<<-- HERE> in m/%s/
3f1b01
 
3f1b01
 (F) You either made a typo or have incorrectly put a C<*> quantifier
3f1b01
-- 
3f1b01
2.26.2
3f1b01