summaryrefslogtreecommitdiff
path: root/Tools/unicode
diff options
context:
space:
mode:
authorJon Dufresne <jon.dufresne@gmail.com>2017-05-18 07:35:54 -0700
committerRaymond Hettinger <rhettinger@users.noreply.github.com>2017-05-18 07:35:54 -0700
commit3972628de3d569c88451a2a176a1c94d8822b8a6 (patch)
tree30627d132c42fb65f96c3d9e209b317f68d175ed /Tools/unicode
parent906f5330b9c9a74cad1cf27fddaf77e99dff9edd (diff)
downloadcpython-git-3972628de3d569c88451a2a176a1c94d8822b8a6.tar.gz
bpo-30296 Remove unnecessary tuples, lists, sets, and dicts (#1489)
* Replaced list(<generator expression>) with list comprehension * Replaced dict(<generator expression>) with dict comprehension * Replaced set(<list literal>) with set literal * Replaced builtin func(<list comprehension>) with func(<generator expression>) when supported (e.g. any(), all(), tuple(), min(), & max())
Diffstat (limited to 'Tools/unicode')
-rw-r--r--Tools/unicode/makeunicodedata.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Tools/unicode/makeunicodedata.py b/Tools/unicode/makeunicodedata.py
index 5d8014a5da..472324fdef 100644
--- a/Tools/unicode/makeunicodedata.py
+++ b/Tools/unicode/makeunicodedata.py
@@ -609,7 +609,7 @@ def makeunicodename(unicode, trace):
if name and name[0] != "<":
names[char] = name + chr(0)
- print(len(list(n for n in names if n is not None)), "distinct names")
+ print(len([n for n in names if n is not None]), "distinct names")
# collect unique words from names (note that we differ between
# words inside a sentence, and words ending a sentence. the