perl: hide dropped features again unless ?v
authorMischa POSLAWSKY <perl@shiar.org>
Wed, 24 Apr 2024 19:34:01 +0000 (21:34 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Thu, 25 Apr 2024 00:13:10 +0000 (02:13 +0200)
Always shown since incorrect fix in commit v1.14-7-ge90c9ada43 (2023-10-29)
[silence warning about skipping dropped features].  Instead of complex
workarounds, just revert and enforce the "unconventional" feature.

perl.plp

index 596e4d84d80afeafe4dece3facdbe662e04d326c..0ee9639da43603d99bdb4a47d090e02d595b4d9f 100644 (file)
--- a/perl.plp
+++ b/perl.plp
@@ -2,7 +2,7 @@
 
 Html({
        title => 'perl version cheat sheet',
 
 Html({
        title => 'perl version cheat sheet',
-       version => '1.6',
+       version => '1.7',
        keywords => [qw'
                perl version feature features comparison
                sheet cheat overview summary
        keywords => [qw'
                perl version feature features comparison
                sheet cheat overview summary
@@ -113,7 +113,8 @@ sub featattrs ($attr) {
                $title = 'experimental';
        }
        if (defined $attr->{dropped}) {
                $title = 'experimental';
        }
        if (defined $attr->{dropped}) {
-               return '' unless exists $get{v};
+               no warnings 'exiting';
+               next unless exists $get{v}; # skip containing feature
                $title = sprintf 'removed in %vd', $_ for $attr->{dropped} || ();
        }
        elsif ($attr->{stable}) {
                $title = sprintf 'removed in %vd', $_ for $attr->{dropped} || ();
        }
        elsif ($attr->{stable}) {