Arcadiy Ivanov <arca...@ivanov.biz> added the comment: @serhiy.storchaka Of course a similar pattern can be implemented via a class (or even without one as I've shown below).
But you can clearly notice that in your example: 1) There are tons of boilerplate (as in mine with lambdas). 2) It's going to be slower than a core implementation with specialized objects. 3) It can't be made to cooperate with a FORMAT_VALUE/BUILD_STRING - intermediate strings will still be produced. ---------- nosy: -eric.smith, serhiy.storchaka _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue32954> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com