Le Wed, 13 Feb 2013 09:02:07 +0100, Victor Stinner firstname.lastname@example.org a écrit :
I added a _PyUnicodeWriter internal API to optimize str%args and str.format(args). It uses a buffer which is overallocated, so it's basically like CPython str += str optimization. I still don't know how efficient it is on Windows, since realloc() is slow on Windows (at least on old Windows versions).
We should add an official and public API to concatenate strings.
There's io.StringIO already.