summaryrefslogtreecommitdiff
path: root/codegen/definitions.py
diff options
context:
space:
mode:
authorGraydon, Tracy <tracy.graydon@intel.com>2012-11-30 12:11:38 -0800
committerGraydon, Tracy <tracy.graydon@intel.com>2012-11-30 12:11:38 -0800
commit1a48cb6e7504163228442a2894af21af66e93eb2 (patch)
tree8d117e9778e44c485d187679bf5250c52e02975d /codegen/definitions.py
parente319390cebb45884f62ca3c2b22984d8ed82b941 (diff)
downloadpygobject2-1a48cb6e7504163228442a2894af21af66e93eb2.tar.gz
pygobject2-1a48cb6e7504163228442a2894af21af66e93eb2.tar.bz2
pygobject2-1a48cb6e7504163228442a2894af21af66e93eb2.zip
Update to 2.28 for TINF-96
Diffstat (limited to 'codegen/definitions.py')
-rw-r--r--codegen/definitions.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/codegen/definitions.py b/codegen/definitions.py
index aca5adb..bfb6faf 100644
--- a/codegen/definitions.py
+++ b/codegen/definitions.py
@@ -71,15 +71,15 @@ class Definition(object):
def __init__(self, *args):
"""Create a new defs object of this type. The arguments are the
components of the definition"""
- raise RuntimeError, "this is an abstract class"
+ raise RuntimeError("this is an abstract class")
def merge(self, old):
"""Merge in customisations from older version of definition"""
- raise RuntimeError, "this is an abstract class"
+ raise RuntimeError("this is an abstract class")
def write_defs(self, fp=sys.stdout):
"""write out this definition in defs file format"""
- raise RuntimeError, "this is an abstract class"
+ raise RuntimeError("this is an abstract class")
def guess_return_value_ownership(self):
"return 1 if caller owns return value"
@@ -407,7 +407,7 @@ class MethodDef(MethodDefBase):
for item in ('c_name', 'of_object'):
if self.__dict__[item] == None:
self.write_defs(sys.stderr)
- raise RuntimeError, "definition missing required %s" % (item,)
+ raise RuntimeError("definition missing required %s" % (item,))
def write_defs(self, fp=sys.stdout):
fp.write('(define-method ' + self.name + '\n')
@@ -491,7 +491,7 @@ class FunctionDef(Definition):
for item in ('c_name',):
if self.__dict__[item] == None:
self.write_defs(sys.stderr)
- raise RuntimeError, "definition missing required %s" % (item,)
+ raise RuntimeError("definition missing required %s" % (item,))
_method_write_defs = MethodDef.__dict__['write_defs']
@@ -513,8 +513,8 @@ class FunctionDef(Definition):
else:
param.merge(old_param)
return param
- raise RuntimeError, "could not find %s in old_parameters %r" % (
- param.pname, [p.pname for p in old.params])
+ raise RuntimeError("could not find %s in old_parameters %r" % (
+ param.pname, [p.pname for p in old.params]))
try:
self.params = map(merge_param, self.params)
except RuntimeError: