summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2006-03-30 21:43:35 (GMT)
committerGuido van Rossum <guido@python.org>2006-03-30 21:43:35 (GMT)
commitc259cc9c4c1c90efaeace2c9786786a5813cf950 (patch)
treeea3deedb2a0ec6a47fc5606786977f6b33eb8693
parent090f81588fc2298b3c967ddda3c3ffc592caf92a (diff)
downloadcpython-c259cc9c4c1c90efaeace2c9786786a5813cf950.zip
cpython-c259cc9c4c1c90efaeace2c9786786a5813cf950.tar.gz
cpython-c259cc9c4c1c90efaeace2c9786786a5813cf950.tar.bz2
Insert a safety space after numbers as well as names in untokenize().
-rw-r--r--Lib/tokenize.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/tokenize.py b/Lib/tokenize.py
index 2b40e6f..a30791c 100644
--- a/Lib/tokenize.py
+++ b/Lib/tokenize.py
@@ -182,7 +182,7 @@ def untokenize(iterable):
for tok in iterable:
toknum, tokval = tok[:2]
- if toknum == NAME:
+ if toknum in (NAME, NUMBER):
tokval += ' '
if toknum == INDENT: