summaryrefslogtreecommitdiff
path: root/Lib/collections
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2016-08-17 00:46:48 -0700
committerRaymond Hettinger <python@rcn.com>2016-08-17 00:46:48 -0700
commit8579a8fd630a0d34f90a0b4745518b362b2ea774 (patch)
tree40c9eb9e57660a5243beab142ad2c48a97b52de6 /Lib/collections
parent4d02b1b2bb77ea8c40dea1e3a2f17949e6ebdc63 (diff)
downloadcpython-git-8579a8fd630a0d34f90a0b4745518b362b2ea774.tar.gz
Minor readability tweak
Diffstat (limited to 'Lib/collections')
-rw-r--r--Lib/collections/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/collections/__init__.py b/Lib/collections/__init__.py
index f465e74770..03ecea27cc 100644
--- a/Lib/collections/__init__.py
+++ b/Lib/collections/__init__.py
@@ -393,7 +393,7 @@ def namedtuple(typename, field_names, *, verbose=False, rename=False):
field_names[index] = '_%d' % index
seen.add(name)
for name in [typename] + field_names:
- if type(name) != str:
+ if type(name) is not str:
raise TypeError('Type names and field names must be strings')
if not name.isidentifier():
raise ValueError('Type names and field names must be valid '