[docs] [issue15952] format(value) and value.__format__() behave differently with unicode format

Eric V. Smith report at bugs.python.org
Mon Sep 17 14:46:46 CEST 2012


Eric V. Smith added the comment:

I believe the conversion is happening in Objects/abstract.c in PyObject_Format, around line 864, near this comment:

    /* Convert to unicode, if needed.  Required if spec is unicode
       and result is str */

I think changing the docs will result in more confusion than clarity, but if you can come up with some good wording, I'd be okay with it. I think changing the code will likely break things with little or no benefit.

----------
nosy: +eric.smith

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue15952>
_______________________________________


More information about the docs mailing list