[pypy-issue] [issue1180] Formatting a bool value is not equal to CPython's result
tracker at bugs.pypy.org
Mon Jun 18 11:43:18 CEST 2012
New submission from Eunchong Yu <kroisse at gmail.com>:
Formatting a `bool` value(True, False) by str.format() returned '1' or '0' on
PyPy 1.8.0, rather than 'True' or 'False' like the CPython's behavior.
Formatting that by the % operator has no problem. Here is my tries:
I tried to explain it, and I found that CPython's bool.__format__() doesn't
override int.__format__(). However, int.__format__() formatted the boolean value
`True` into 'True'.
nosy: kroisse, pypy-issue
title: Formatting a bool value is not equal to CPython's result
PyPy bug tracker <tracker at bugs.pypy.org>
More information about the pypy-issue