summaryrefslogtreecommitdiffstats
path: root/Mac/Modules
diff options
context:
space:
mode:
authorCollin Winter <collinw@gmail.com>2007-08-22 23:05:23 (GMT)
committerCollin Winter <collinw@gmail.com>2007-08-22 23:05:23 (GMT)
commit1dd46a048f4afd9a3bc1e3c9c1603d26f2e33e27 (patch)
tree4b258391e4693a7fa9db93c30b10414d6480112a /Mac/Modules
parenta817e5894b20d68263056bf9af8f1582954b1d8f (diff)
downloadcpython-1dd46a048f4afd9a3bc1e3c9c1603d26f2e33e27.zip
cpython-1dd46a048f4afd9a3bc1e3c9c1603d26f2e33e27.tar.gz
cpython-1dd46a048f4afd9a3bc1e3c9c1603d26f2e33e27.tar.bz2
Convert raise statements in Mac/.
Diffstat (limited to 'Mac/Modules')
-rw-r--r--Mac/Modules/cf/cfsupport.py6
-rw-r--r--Mac/Modules/file/filesupport.py2
-rw-r--r--Mac/Modules/list/listsupport.py2
-rw-r--r--Mac/Modules/te/tesupport.py2
4 files changed, 6 insertions, 6 deletions
diff --git a/Mac/Modules/cf/cfsupport.py b/Mac/Modules/cf/cfsupport.py
index 655331e..23c8598 100644
--- a/Mac/Modules/cf/cfsupport.py
+++ b/Mac/Modules/cf/cfsupport.py
@@ -24,14 +24,14 @@ class MethodSkipArg1(MethodGenerator):
def parseArgumentList(self, args):
if len(args) < 2:
- raise ValueError, "MethodSkipArg1 expects at least 2 args"
+ raise ValueError("MethodSkipArg1 expects at least 2 args")
a0, a1, args = args[0], args[1], args[2:]
t0, n0, m0 = a0
if t0 != "CFAllocatorRef" and m0 != InMode:
- raise ValueError, "MethodSkipArg1 should have dummy AllocatorRef first arg"
+ raise ValueError("MethodSkipArg1 should have dummy AllocatorRef first arg")
t1, n1, m1 = a1
if m1 != InMode:
- raise ValueError, "method's 'self' must be 'InMode'"
+ raise ValueError("method's 'self' must be 'InMode'")
dummy = Variable(t0, n0, m0)
self.argumentList.append(dummy)
self.itself = Variable(t1, "_self->ob_itself", SelfMode)
diff --git a/Mac/Modules/file/filesupport.py b/Mac/Modules/file/filesupport.py
index de45ed4..8211724 100644
--- a/Mac/Modules/file/filesupport.py
+++ b/Mac/Modules/file/filesupport.py
@@ -774,7 +774,7 @@ class Arg2MethodGenerator(OSErrMethodGenerator):
t0, n0, m0 = arg1
args = args0 + argsrest
if m0 != InMode:
- raise ValueError, "method's 'self' must be 'InMode'"
+ raise ValueError("method's 'self' must be 'InMode'")
self.itself = Variable(t0, "_self->ob_itself", SelfMode)
FunctionGenerator.parseArgumentList(self, args)
self.argumentList.insert(2, self.itself)
diff --git a/Mac/Modules/list/listsupport.py b/Mac/Modules/list/listsupport.py
index 2e1144a..1c12206 100644
--- a/Mac/Modules/list/listsupport.py
+++ b/Mac/Modules/list/listsupport.py
@@ -70,7 +70,7 @@ class ListMethodGenerator(MethodGenerator):
args, a0 = args[:-1], args[-1]
t0, n0, m0 = a0
if m0 != InMode:
- raise ValueError, "method's 'self' must be 'InMode'"
+ raise ValueError("method's 'self' must be 'InMode'")
self.itself = Variable(t0, "_self->ob_itself", SelfMode)
FunctionGenerator.parseArgumentList(self, args)
self.argumentList.append(self.itself)
diff --git a/Mac/Modules/te/tesupport.py b/Mac/Modules/te/tesupport.py
index 412d5e7..96c9604 100644
--- a/Mac/Modules/te/tesupport.py
+++ b/Mac/Modules/te/tesupport.py
@@ -82,7 +82,7 @@ class TEMethodGenerator(OSErrWeakLinkMethodGenerator):
args, a0 = args[:-1], args[-1]
t0, n0, m0 = a0
if m0 != InMode:
- raise ValueError, "method's 'self' must be 'InMode'"
+ raise ValueError("method's 'self' must be 'InMode'")
self.itself = Variable(t0, "_self->ob_itself", SelfMode)
FunctionGenerator.parseArgumentList(self, args)
self.argumentList.append(self.itself)