[Python-ideas] Draft2 PEP on string interpolation

Guido van Rossum guido at python.org
Fri Aug 28 17:11:14 CEST 2015


Thanks, this looks much better, if we ever want to go in this direction.
(Though I think you may want to separate the field names into two parts,
the expression text and the format spec.)

Can you work with the team at peps at python.org to get a PEP number for this?

On Fri, Aug 28, 2015 at 1:34 AM, Mike Miller <python-ideas at mgmiller.net>
wrote:

> Hi,
>
> I was able to get this done tonight.  There's still simplifications to be
> done, perhaps keeping the string fragments in one piece?  Also, a lot of
> things need to be passed to the constructor to avoid parsing the template
> twice.
>
> Positional arguments are working however, and we're back to inheriting
> from str.  It is now rendering into the "real" string, and everything seems
> to work without the magic methods.  ;)
>
> Thanks,
>
> -Mike
>
> On 08/27/2015 02:02 PM, Guido van Rossum wrote:
>



-- 
--Guido van Rossum (python.org/~guido)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20150828/04a1f9d9/attachment.html>


More information about the Python-ideas mailing list