Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: v5.22.0: Redundant argument in %s versus minimum width in sprintf

by Anonymous Monk
on Jul 01, 2015 at 06:55 UTC ( [id://1132760]=note: print w/replies, xml ) Need Help??


in reply to v5.22.0: Redundant argument in %s versus minimum width in sprintf

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

  • Comment on Re: v5.22.0: Redundant argument in %s versus minimum width in sprintf
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1132760]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (7)
As of 2024-04-23 20:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found