This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perldelta - Consistent use of C<> and L<>
[perl5.git] / pod / perldiag.pod
index d2a1471..23f147d 100644 (file)
@@ -214,6 +214,13 @@ point and did not attempt to push this layer.  If your program
 didn't explicitly request the failing operation, it may be the
 result of the value of the environment variable PERLIO.
 
+=item Argument "%s" treated as 0 in increment (++)
+
+(W numeric) The indicated string was fed as an argument to the C<++>
+operator which expects either a number or a string matching
+C</^[a-zA-Z]*[0-9]*\z/>.  See L<perlop/Auto-increment and
+Auto-decrement> for details.
+
 =item Array @%s missing the @ in argument %d of %s()
 
 (D deprecated) Really old Perl let you omit the @ on array names in some
@@ -2170,8 +2177,8 @@ has since been undefined.
 <-- HERE in m/%s/
 
 (F) Group names must follow the rules for perl identifiers, meaning
-they must start with a non-digit word character. A common cause of
-this error is using (?&0) instead of (?0). See L<perlre>.
+they must start with a non-digit word character.  A common cause of
+this error is using (?&0) instead of (?0).  See L<perlre>.
 
 =item ()-group starts with a count
 
@@ -2230,8 +2237,10 @@ offending digit.
 
 =item Illegal character after '_' in prototype for %s : %s
 
-(W illegalproto) An illegal character was found in a prototype declaration.
-Legal characters in prototypes are $, @, %, *, ;, [, ], &, \, and +.
+(W illegalproto) An illegal character was found in a prototype
+declaration.  The '_' in a prototype must be followed by a ';',
+indicating the rest of the parameters are optional, or one of '@'
+or '%', since those two will accept 0 or more final parameters.
 
 =item Illegal character \%o (carriage return)
 
@@ -2614,7 +2623,7 @@ an arbitrary reference was blessed into the "version" class.
 (D regexp, deprecated) The two-character sequence C<"(*"> in
 this context in a regular expression pattern should be an
 indivisible token, with nothing intervening between the C<"(">
-and the C<"*">, but you separated them. Due to an accident of
+and the C<"*">, but you separated them.  Due to an accident of
 implementation, this prohibition was not enforced, but we do
 plan to forbid it in a future Perl version.  This message
 serves as giving you fair warning of this pending change.
@@ -2802,6 +2811,12 @@ foo :lvalue;> declaration before the definition.
 
 See also L<attributes.pm|attributes>.
 
+=item Magical list constants are not supported
+
+(F) You assigned a magical array to a stash element, and then tried
+to use the subroutine from the same slot.  You are asking Perl to do
+something it cannot do, details subject to change between Perl versions.
+
 =item Malformed integer in [] in pack
 
 (F) Between the brackets enclosing a numeric repeat count only digits
@@ -2979,6 +2994,11 @@ they have a name with which they can be found.
 are always mentioned with the $ in Perl, unlike in the shells, where it
 can vary from one line to the next.
 
+=item Missing ']' in prototype for %s : %s
+
+(W illegalproto) A grouping was started with C<[> but never closed with
+C<]>.
+
 =item (Missing operator before %s?)
 
 (S syntax) This is an educated guess made in conjunction with the message
@@ -3119,13 +3139,15 @@ local() if you want to localize a package variable.
 
 (W once) Typographical errors often show up as unique variable names.
 If you had a good reason for having a unique name, then just mention it
-again somehow to suppress the message.  The C<our> declaration is
-provided for this purpose.
+again somehow to suppress the message.  The C<our> declaration is provided
+for this purpose.
 
 NOTE: This warning detects symbols that have been used only once so $c, @c,
 %c, *c, &c, sub c{}, c(), and c (the filehandle or format) are considered
 the same; if a program uses $c only once but also uses any of the others it
-will not trigger this warning.
+will not trigger this warning.  Symbols beginning with an underscore and
+symbols using special identifiers (q.v. L<perldata>) are exempt from this
+warning.
 
 =item Need exactly 3 octal digits in regex; marked by <-- HERE in m/%s/
 
@@ -4016,12 +4038,10 @@ that a method requires a package that has not been loaded.
 =item Perl folding rules are not up-to-date for 0x%X; please use the perlbug 
 utility to report; in regex; marked by <-- HERE in m/%s/
 
-(D regexp, deprecated) You used a regular expression with
-case-insensitive matching, and there is a bug in Perl in which the
-built-in regular expression folding rules are not accurate.  This
-may lead to incorrect results.  Please report this as a bug using the
-L<perlbug> utility.  (This message is marked deprecated, so that it by
-default will be turned-on.)
+(S regexp) You used a regular expression with case-insensitive matching,
+and there is a bug in Perl in which the built-in regular expression
+folding rules are not accurate.  This may lead to incorrect results.
+Please report this as a bug using the L<perlbug> utility.
 
 =item Perl_my_%s() not available
 
@@ -5141,7 +5161,7 @@ target of the change to
 
 (F) Something has attempted to use an internal API call which
 depends on Perl being compiled with the default support for randomized hash
-key traversal, but this Perl has been compiled without it. You should
+key traversal, but this Perl has been compiled without it.  You should
 report this warning to the relevant upstream party, or recompile perl
 with default options.
 
@@ -5384,6 +5404,16 @@ enough to figure out what you really meant.
 (P) When compiling a subroutine call in lvalue context, Perl failed an
 internal consistency check.  It encountered a malformed op tree.
 
+=item Unexpected exit %u
+
+(S) exit() was called or the script otherwise finished gracefully when
+C<PERL_EXIT_WARN> was set in C<PL_exit_flags>.
+
+=item Unexpected exit failure %u
+
+(S) An uncaught die() was called when C<PERL_EXIT_WARN> was set in
+C<PL_exit_flags>.
+
 =item Unexpected ')' in regex; marked by <-- HERE in m/%s/
 
 (F) You had something like this:
@@ -5502,7 +5532,7 @@ discovered.  See L<perlre>.
 (F) You specified an unknown Unicode option.  See L<perlrun> documentation
 of the C<-C> switch for the list of known options.
 
-=item Unknown Unicode option value %x
+=item Unknown Unicode option value %d
 
 (F) You specified an unknown Unicode option.  See L<perlrun> documentation
 of the C<-C> switch for the list of known options.
@@ -5921,9 +5951,9 @@ used.  (This may change in the future.)
 
 =item Use of each() on hash after insertion without resetting hash iterator results in undefined behavior
 
-(S internal) The behavior of C<each()> after insertion is undefined; it may
-skip items, or visit items more than once. Consider using C<keys()> instead
-of C<each()>.
+(S internal) The behavior of C<each()> after insertion is undefined;
+it may skip items, or visit items more than once.  Consider using
+C<keys()> instead of C<each()>.
 
 =item Use of := for an empty attribute list is not allowed