[Python-ideas] Disallow "00000" as a synonym for "0"

Steven D'Aprano steve at pearwood.info
Sun Jul 19 05:17:57 CEST 2015


On Sat, Jul 18, 2015 at 03:40:28PM -0400, Ron Adam wrote:

> And then there is this...
> 
> >>> 000.0
> 0.0
> >>> 000.1
> 0.1

The parsing rules for floats are not the same as int, and since floats 
always use decimal, never octal, there's no ambiguity or confusion from 
writing "0000.0000". I don't propose changing floats.

-- 
Steve


More information about the Python-ideas mailing list