in reply to Re: diagnostics: warning, deprecation, error
in thread diagnostics: warning, deprecation, error

no longer supported

perl -MConfig=compile_date -le'$|++;for(`perldoc -u perldiag`){print${ +1}and$-++if/^=item\s+(\S\S.*)$/}print(($-+1)," diagnostic warnings, d +eprecations, errors in perl $^V ").compile_date()' | grep -i 'no long +er supported'
\C no longer supported in regex; marked by S<<-- HERE> in m/%s/
${^ENCODING} is no longer supported
$* is no longer supported as of Perl 5.30
$# is no longer supported as of Perl 5.30

did you mean

perl -MConfig=compile_date -le'$|++;for(`perldoc -u perldiag`){print${ +1}and$-++if/^=item\s+(\S\S.*)$/}print(($-+1)," diagnostic warnings, d +eprecations, errors in perl $^V ").compile_date()' | grep -i 'did you + mean'
(Did you mean &%s instead?)
(Did you mean "local" instead of "our"?)
(Did you mean $ or @ instead of %?)
do "%s" failed, '.' is no longer in @INC; did you mean do "./%s"?
length() used on %s (did you mean "scalar(%s)"?)
Perl %s required (did you mean %s?)--this is only %s, stopped
$[ used in %s (did you mean $] ?)

crash

perl -MConfig=compile_date -le'$|++;for(`perldoc -u perldiag`){print${ +1}and$-++if/^=item\s+(\S\S.*)$/}print(($-+1)," diagnostic warnings, d +eprecations, errors in perl $^V ").compile_date()' | grep -i crash
Locale '%s' is unsupported, and may crash the interpreter

Replies are listed 'Best First'.
Re^3: diagnostics: warning, deprecation, error
by ikegami (Patriarch) on Feb 10, 2026 at 17:48 UTC

    Do you have a point or a question?

      Usual perl error:
      perl -MSuper::Duper -e 'print Super::Duper->new->thing'

      Can't locate Super/Duper.pm in @INC (you may need to install the Super::Duper module) (@INC entries checked: /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/site_perl/5.42.0/darwin-2level /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/site_perl/5.42.0 /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/5.42.0/darwin-2level /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/5.42.0).
      BEGIN failed--compilation aborted.
      

      Improved perl error:
      perl -MIPC::Cmd=run -le '@_=run(command=>"perl -MSuper::Duper");$_=joi +n"",@{$_[2]};s/ ([\(])/\n/g;s/ ([\/])/\n $1/g;s/\)//g;chomp;print'

      Can't locate Super/Duper.pm in @INC
      you may need to install the Super::Duper module
      @INC entries checked:
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/site_perl/5.42.0/darwin-2level
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/site_perl/5.42.0
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/5.42.0/darwin-2level
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/5.42.0.
      BEGIN failed--compilation aborted.
      

      Ideal perl error? (formatted nice like perl -v):
      Can't locate Super/Duper.pm in @INC
      See: perldoc -v @INC
      
      You may need to install the Super::Duper module!
      https://metacpan.org/search?q=Super::Duper
      
      @INC entries checked:
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/site_perl/5.42.0/darwin-2level
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/site_perl/5.42.0
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/5.42.0/darwin-2level
       /Users/u/perl5/perlbrew/perls/perl-5.42.0/lib/5.42.0.
      
      BEGIN failed--compilation aborted.
      

        This is much nicer, and I guess I've always just accepted the way it is now for historic reasons, it looked liked this since I first experienced it, and I knew what it meant and what to do. I'm putting together a patch that makes it look like your suggestion:

        ./perl -MDerp::Derp Can't locate Derp/Derp.pm in @INC See: perldoc -v @INC You may need to install the Derp::Derp module: https://metacpan.org/search?q=Derp::Derp @INC entries checked: /home/marto/localperl/lib/site_perl/5.42.0/x86_64-linux /home/marto/localperl/lib/site_perl/5.42.0 /home/marto/localperl/lib/5.42.0/x86_64-linux /home/marto/localperl/lib/5.42.0. BEGIN failed--compilation aborted. ~/localperl/bin

        But need to fix the breaking tests that go looking for the old format in:

        Failed 5 tests out of 2667, 99.81% okay. ../cpan/Test-Simple/t/Legacy/fail-more.t ../cpan/parent/t/parent.t op/inccode-tie.t op/inccode.t op/require_errors.t