summaryrefslogtreecommitdiffstats
path: root/Doc/tools/sgmlconv/esistools.py
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/tools/sgmlconv/esistools.py')
-rw-r--r--Doc/tools/sgmlconv/esistools.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/Doc/tools/sgmlconv/esistools.py b/Doc/tools/sgmlconv/esistools.py
index 6dc5eaa..11f458e 100644
--- a/Doc/tools/sgmlconv/esistools.py
+++ b/Doc/tools/sgmlconv/esistools.py
@@ -29,7 +29,7 @@ def decode(s):
n, s = s.split(";", 1)
r = r + unichr(int(n))
else:
- raise ValueError, "can't handle %r" % s
+ raise ValueError("can't handle %r" % s)
return r
@@ -80,7 +80,7 @@ class ESISReader(xml.sax.xmlreader.XMLReader):
self.setErrorHandler(errorHandler)
def get_empties(self):
- return self._empties.keys()
+ return list(self._empties.keys())
#
# XMLReader interface
@@ -270,7 +270,7 @@ class Attributes(xml.sax.xmlreader.AttributesImpl):
return self._attrs[name][0]
def get(self, name, default=None):
- if self._attrs.has_key(name):
+ if name in self._attrs:
return self._attrs[name][0]
return default
@@ -282,7 +282,7 @@ class Attributes(xml.sax.xmlreader.AttributesImpl):
def values(self):
L = []
- for value, type in self._attrs.values():
+ for value, type in list(self._attrs.values()):
L.append(value)
return L