On Wed, Jun 22, 2016, at 10:19, Grant Edwards wrote: > Is that guaranteed by Python, or just a side-effect of the > implementation? Back in the days when Python used native C integers I > think the latter.
AIUI, native C integers have never reliably supported signed zero even with representations that naively seem to have it. There's no well-defined way to detect it - no int version of copysign, for instance - and implementations are free to erase the distinction on every load/store or define one of them to be a trap representation. -- https://mail.python.org/mailman/listinfo/python-list