Numeric literal syntax

Alexander Schmolck a.schmolck at gmail.com
Thu Sep 4 05:47:07 EDT 2008


bearophileHUGS at lycos.com writes:

> A problem is that '1234' in Python is a string, so using ' in numbers
> looks a bit dangerous to me (and my editor will color those numbers as
> alternated strings, I think).

Yeah, editors, especially those with crummy syntax highlighting (like emacs)
might get it wrong. This should be easy enough to fix though. Indeed unlike
raw and tripplequoted strings which were adopted without major hitches this
new syntax wouldn't have any bearing on what's a valid string.

'as




More information about the Python-list mailing list