Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: Re: multi-lingual support...

by wog (Curate)
on Jan 05, 2002 at 03:44 UTC ( #136418=note: print w/replies, xml ) Need Help??

in reply to Re: multi-lingual support...
in thread multi-lingual support...

Note that if you want to be able to change the order of parameters you will need to add yet an other indirection layer...

update: Okay... I should check docs less recent then the latest development version. Read this as "you won't have to in the next version of perl".

Actually, you won't. To quote the sprintf docs:

Perl supports parameter ordering, in other words, fetching the parameters in some explicitly speci fied "random" ordering as opposed to the default implicit sequential ordering. The syntax is, instead of the "%" and "*", to use "%"digits"$" and "*"digits"$", where the digits is the wanted index, from one upwards. For example:
printf "%2\$d %1\$d\n", 12, 34; # will print "34 12\n" printf "%*2\$d\n", 12, 3; # will print " 12\n"
(... more stuff on this topic omitted ...)

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://136418]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2017-02-19 19:34 GMT
Find Nodes?
    Voting Booth?
    Before electricity was invented, what was the Electric Eel called?

    Results (293 votes). Check out past polls.