Antoine Pitrou added the comment: > > I would like to know why that is the case. > > If PyUnicode_Join is not optimal, then perhaps we should > > better optimize it. > > I don't know. _PyUnicodeWriter overallocates its buffer (+25%). It may > reduce the number of realloc(), and so the number of times that the > buffer is copied.
But PyUnicode_Join doesn't realloc() anything, since it creates a buffer of exactly the right size. So this can't be the answer. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue15612> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com