ATM http://perldoc.perl.org/functions/sprintf.html#%28minimum%29-width says Perl 5 version 20.1 documentation
https://metacpan.org/pod/perlfunc#sprintf-FORMAT-LIST is ATM v5.22.0 current
The introduction Bug #121025 for perl5: printf warns about too few arguments, but not too many
Add a new warning about redundant printf arguments
I guess its a bug in the warnings ...
bugs like this are frequent ( not testing stuff thats in the documentation, then it breaks)
But then again http://perl5.git.perl.org/perl.git/blob/HEAD:/t/op/sprintf.t
647 >%y< >''< >%y INVALID REDUNDANT< 648 >%z< >''< >%z INVALID REDUNDANT< 649 >%2$d %1$d< >[12, 34]< >34 12< 650 >%*2$d< >[12, 3]< > 12 REDUNDANT< 651 >%2$d %d< >[12, 34]< >34 12< 652 >%2$d %d %d< >[12, 34]< >34 12 34< 653 >%3$d %d %d< >[12, 34, 56]< >56 12 34< 654 >%2$*3$d %d< >[12, 34, 3]< > 34 12< 655 >%*3$2$d %d< >[12, 34, 3]< >%*3$2$d 12 INVALID REDUNDANT<
It also happens frequently that stuff gets implemented by those who don't understand how it works .... so this needs a new bug on rt because one of these things is wrong , whichever one it is
In reply to Re: v5.22.0: Redundant argument in %s versus minimum width in sprintf
by Anonymous Monk
in thread v5.22.0: Redundant argument in %s versus minimum width in sprintf
by JadeNB
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |