[Python-Dev] Re: Update PEP 292

Barry Warsaw barry at python.org
Fri Aug 20 17:05:27 CEST 2004


On Thu, 2004-08-19 at 19:22, Raymond Hettinger wrote:

>     IDLE 1.1a2      
>     >>> from Cheetah.Template import Template
>     >>> t = Template('the $rank is $@ a $$ dead ${rank}! $')
>     >>> t.rank='king'
>     >>> print t
>     the king is $@ a $$ dead king! $

There's a neat idea buried in there: Templates taking an interpolation
mapping from their attributes.

-Barry

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 307 bytes
Desc: This is a digitally signed message part
Url : http://mail.python.org/pipermail/python-dev/attachments/20040820/fe36fcea/attachment.pgp


More information about the Python-Dev mailing list