develooper Front page | perl.perl5.porters | Postings from September 2011

Re: [perl #100190] RFE: fix sprintf to be consistent with printf andbe useful!

Thread Previous | Thread Next
From:
Eric Brine
Date:
September 30, 2011 01:45
Subject:
Re: [perl #100190] RFE: fix sprintf to be consistent with printf andbe useful!
Message ID:
CALJW-qHsehweU5HahgHz3Oc47iARpNe-ttk4kTZk3nm6+8P=6Q@mail.gmail.com
On Fri, Sep 30, 2011 at 1:52 AM, Johan Vromans <jvromans@squirrel.nl> wrote:

> [Quoting Eric Brine, on September 29 2011, 18:21, in "Re: [perl #100190]
> R"]
> >      sub my_printf { print ">> " . sprintf(@_) }
> >     but need
> >      sub my_printf { print ">> " . sprintf( $_[0], @_[1..$#_] ) }
> >
> > Except the same thing applies to every single builtin (e.g. length,
> > splice, substr, exit, etc.)
>
> Which, IMNSHO, indicates there's something counter-intuitive with the
> way these builtins are handled.
>

Yes, prototypes are recognised as being problematic.

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About