develooper Front page | perl.perl6.language | Postings from March 2005

Re: A possible solution for s?pintf

Thread Previous | Thread Next
Larry Wall
March 13, 2005 17:26
Re: A possible solution for s?pintf
Message ID:
On Sat, Mar 12, 2005 at 05:12:30PM -0800, Dave Whipp wrote:
: Larry Wall wrote:
: >I don't see that this buys us anything over just shortening "sprintf"
: >to something shorter, like:
: >
: >   print as '%03d %15s', $foo, $bar;
: >
: >And your argument list falls out naturally from making "as" a listop.
: >Plus it naturally lets you say other "as-ly" things:
: >
: >   print as MyBigInt, $foo, $bar;
: This seems to have some overlap with the "form" listop in E7. Do we need 
: both, or will we make c<Form> a possible 1st arg to C<<as>.

That would be up to Damian.  :-)

:         print as Form :interleave <<'.'

I don't think that can be valid syntax--too many nouns in a row, and if
you take :interleave as an adverb, it'd have to apply to "as" rather than
than "Form".

Here docs are now q:here<.> or q:till<.> or some such, by the way.  So maybe
we just let Damian define q:f:to/./ or some such, except that we already
make :f mean something, I expect.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About