This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Fix outdated note in perldiag
[perl5.git] / pod / perldiag.pod
index 4511dac..0ac367b 100644 (file)
@@ -839,6 +839,13 @@ C<foreach> loop nor a C<given> block.  (Note that this error is
 issued on exit from the C<default> block, so you won't get the
 error if you use an explicit C<continue>.)
 
+=item Can't determine class of operator %s, assuming BASEOP
+
+(S) This warning indicates something wrong in the internals of perl.
+Perl was trying to find the class (e.g. LISTOP) of a particular OP,
+and was unable to do so. This is likely to be due to a bug in the perl
+internals, or due to a bug in XS code which manipulates perl optrees.
+
 =item Can't do inplace edit: %s is not a regular file
 
 (S inplace) You tried to use the B<-i> switch on a special file, such as
@@ -3112,7 +3119,7 @@ neither as a system call nor an ioctl call (SIOCATMARK).
 Perl.  The current valid ones are given in
 L<perlrebackslash/\b{}, \b, \B{}, \B>.
 
-=item %s() is deprecated on :utf8 handles
+=item %s() is deprecated on :utf8 handles. This will be a fatal error in Perl 5.30
 
 (D deprecated) The sysread(), recv(), syswrite() and send() operators are
 deprecated on handles that have the C<:utf8> layer, either explicitly, or
@@ -3128,9 +3135,10 @@ the layer is some different encoding, such as the example above.
 
 Ideally, all of these operators would completely ignore the C<:utf8> state,
 working only with bytes, but this would result in silently breaking existing
-code.  To avoid this a future version of perl will throw an exception when
-any of sysread(), recv(), syswrite() or send() are called on handle with the
-C<:utf8> layer.
+code.
+
+In Perl 5.30, it will no longer be possible to use sysread(), recv(),
+syswrite() or send() to read or send bytes from/to :utf8 handles.
 
 =item "%s" is more clearly written simply as "%s" in regex. This will be a fatal error in Perl 5.28; marked by S<<-- HERE> in m/%s/
 
@@ -3140,6 +3148,28 @@ You specified a character that has the given plainer way of writing it,
 and which is also portable to platforms running with different character
 sets. This usage is deprecated, and will be a fatal error in Perl 5.28.
 
+=item $* is no longer supported. Its use will be fatal in Perl 5.30
+
+(D deprecated, syntax) The special variable C<$*>, deprecated in older
+perls, has been removed as of 5.10.0 and is no longer supported.  In
+previous versions of perl the use of C<$*> enabled or disabled multi-line
+matching within a string.
+
+Instead of using C<$*> you should use the C</m> (and maybe C</s>) regexp
+modifiers.  You can enable C</m> for a lexical scope (even a whole file)
+with C<use re '/m'>.  (In older versions: when C<$*> was set to a true value
+then all regular expressions behaved as if they were written using C</m>.)
+
+Use of this variable will be a fatal error in Perl 5.30.
+
+=item $# is no longer supported. Its use will be fatal in Perl 5.30
+
+(D deprecated, syntax) The special variable C<$#>, deprecated in older
+perls, has been removed as of 5.10.0 and is no longer supported.  You
+should use the printf/sprintf functions instead.
+
+Use of this variable will be a fatal error in Perl 5.30.
+
 =item '%s' is not a code reference
 
 (W overload) The second (fourth, sixth, ...) argument of
@@ -3377,7 +3407,7 @@ the variable, C<%s>, part of the message.
 
 One possible cause is that you set the UTF8 flag yourself for data that
 you thought to be in UTF-8 but it wasn't (it was for example legacy
-8-bit data).  To guard against this, you can use Encode::decode_utf8.
+8-bit data).  To guard against this, you can use C<Encode::decode('UTF-8', ...)>.
 
 If you use the C<:encoding(UTF-8)> PerlIO layer for input, invalid byte
 sequences are handled gracefully, but if you use C<:utf8>, the flag is
@@ -4217,9 +4247,7 @@ L<perlport> for more on portability concerns.
 (F) A subroutine using a slurpy hash parameter in its signature
 received an odd number of arguments to populate the hash.  It requires
 the arguments to be paired, with the same number of keys as values.
-The caller of the subroutine is presumably at fault.  Inconveniently,
-this error will be reported at the location of the subroutine, not that
-of the caller.
+The caller of the subroutine is presumably at fault.
 
 =item Odd number of arguments for overload::constant
 
@@ -7003,12 +7031,12 @@ middle of an iteration causes Perl to see a freed value.
 operator.  Since C<split> always tries to match the pattern
 repeatedly, the C</g> has no effect.
 
-=item Use of "goto" to jump into a construct is deprecated. Its use will be fatal in Perl 5.28
+=item Use of "goto" to jump into a construct is deprecated
 
 (D deprecated) Using C<goto> to jump from an outer scope into an inner
 scope is deprecated and should be avoided.
 
-This was deprecated in Perl 5.12, and will be a fatal error in Perl 5.28.
+This was deprecated in Perl 5.12.
 
 =item Use of inherited AUTOLOAD for non-method %s() is deprecated. This will be fatal in Perl 5.28
 
@@ -7065,13 +7093,15 @@ its behavior may change or even be removed in any future release of perl.
 See the explanation under L<perlvar/$_>.
 
 =item Use of strings with code points over 0xFF as arguments to %s
-operator is deprecated
+operator is deprecated. This will be a fatal error in Perl 5.28
 
 (D deprecated) You tried to use one of the string bitwise operators
 (C<&> or C<|> or C<^> or C<~>) on a string containing a code point over
 0xFF.  The string bitwise operators treat their operands as strings of
 bytes, and values beyond 0xFF are nonsensical in this context.
 
+Such usage will be a fatal error in Perl 5.28.
+
 =item Use of tainted arguments in %s is deprecated
 
 (W taint, deprecated) You have supplied C<system()> or C<exec()> with multiple
@@ -7080,7 +7110,7 @@ but will become a fatal error in a future version of perl.  Untaint your
 arguments.  See L<perlsec>.
 
 =item Use of unassigned code point or non-standalone grapheme for a
-delimiter will be a fatal error starting in Perl v5.30
+delimiter will be a fatal error starting in Perl 5.30
 
 (D deprecated)
 A grapheme is what appears to a native-speaker of a language to be a