string interpolation for python

Yingjie Lan lanyjie at yahoo.com
Mon Apr 2 08:40:14 EDT 2012


...
> That, by the way, is perhaps the biggest problem with this idea of 

> dynamic strings: not that it is too powerful, but that it is TOO WEAK. 
...
> and similar for both format() and Template.


Seems you miss understood my notion of dynamic string.
Dynamic strings are expressions in disguise: the things
in between $...$ are plain old expressions (with optional 
formatting specifications). They are evaluated
as if they were outside the dynamic string. We put them
in there to to kill two birds with one stone: 
   1) ease of reading;
   2) place holding.

Cheers,
Yingjie



More information about the Python-list mailing list