On Tue, Jul 04, 2006 at 05:06:54PM +1000, Brad Bowman wrote:
> Hello,
> 
> It seems that sprintf is will still be around in Perl 6 [1],
> and that sprintf formats will be available using the .as() method.
> While looking at some Python docs [2] I noticed two things that might
> be worth stealing; a sprintf operator (%) and named parameters in 
> the format string:
> 
> a = '%(lang)s has %(c)03d quote types.' % {'c':2, 'lang':'Python}

> The operator need is less clear cut.  Overloading '%' certainly wouldn't
> make sense in Perl 6 and the presence of .as() may cover the common cases.

I'm not convinced that sprintf needs an operator. It's not commonly used in
any code I've looked at, which to me suggests that it's not good huffman
coding to use up a terse symbol for it, denying that symbol to something
else.

Nicholas Clark

Reply via email to