Raise statement normalization in Lib/.

This commit is contained in:
Collin Winter 2007-08-30 01:19:48 +00:00
parent 8b3febef2f
commit ce36ad8a46
80 changed files with 502 additions and 530 deletions

View file

@ -62,7 +62,7 @@ def _reduce_ex(self, proto):
state = None
else:
if base is self.__class__:
raise TypeError, "can't pickle %s objects" % base.__name__
raise TypeError("can't pickle %s objects" % base.__name__)
state = base(self)
args = (self.__class__, base, state)
try:
@ -153,7 +153,7 @@ def add_extension(module, name, code):
"""Register an extension code."""
code = int(code)
if not 1 <= code <= 0x7fffffff:
raise ValueError, "code out of range"
raise ValueError("code out of range")
key = (module, name)
if (_extension_registry.get(key) == code and
_inverted_registry.get(code) == key):