Eric V. Smith added the comment:

I considered doing this, and have some of it implemented. I discussed it with 
Larry Hastings and Mark Shannon at PyCon Ireland, and we decided to just use 
''.format() and the new FORMAT_VALUE opcode, since that was the simplest way to 
fix the previous implementation's faults. That doesn't mean I've given up on 
improving it, of course.

The speed increase would indeed come from avoiding the LOAD_ATTR lookup, not 
building list, and not calling a function.

I'm curious about your benchmarks. Can you share them? I've found f-strings to 
be typically faster than .format(). But I can't say my benchmarks are 
particularly awesome.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27078>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to