diff options
author | Murray Cumming <murrayc@murrayc.com> | 2008-07-13 19:19:29 +0000 |
---|---|---|
committer | Paul Pogonyshev <paulp@src.gnome.org> | 2008-07-13 19:19:29 +0000 |
commit | bf54bf828952b5c38f3e230dae9e1f9557c5e469 (patch) | |
tree | 9b0dcaf69e1de80b0de881793c4d7951ce8a8d52 /codegen/h2def.py | |
parent | eaca30050adb0730653c8f9f434fedb4ffbf5164 (diff) | |
download | pygobject-bf54bf828952b5c38f3e230dae9e1f9557c5e469.tar.gz pygobject-bf54bf828952b5c38f3e230dae9e1f9557c5e469.tar.xz pygobject-bf54bf828952b5c38f3e230dae9e1f9557c5e469.zip |
clean_func(): Strip GSEAL out, to avoid us thinking that there are many
2008-07-08 Murray Cumming <murrayc@murrayc.com>
* codegen/h2def.py: clean_func(): Strip GSEAL out, to avoid us
thinking that there are many functions called GSEAL (merge from
PyGTK).
2008-01-29 Olivier Crete <tester@tester.ca>
* codegen/h2def.py (DefsWriter.__init__): Fix copy-paste
typos (merge from PyGTK).
svn path=/trunk/; revision=794
Diffstat (limited to 'codegen/h2def.py')
-rwxr-xr-x | codegen/h2def.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/codegen/h2def.py b/codegen/h2def.py index 9750598..db62cee 100755 --- a/codegen/h2def.py +++ b/codegen/h2def.py @@ -247,6 +247,10 @@ def clean_func(buf): buf = string.replace(buf, 'G_CONST_RETURN ', 'const-') buf = string.replace(buf, 'const ', 'const-') + #strip GSEAL macros from the middle of function declarations: + pat = re.compile(r"""GSEAL""", re.VERBOSE) + buf = pat.sub('', buf) + return buf proto_pat=re.compile(r""" @@ -281,9 +285,9 @@ class DefsWriter: for func in filter.functions + filter.methods.values(): self._functions[func.c_name] = func for obj in filter.objects + filter.boxes + filter.interfaces: - self._objects[obj.c_name] = func + self._objects[obj.c_name] = obj for obj in filter.enums: - self._enums[obj.c_name] = func + self._enums[obj.c_name] = obj def write_def(self, deffile): buf = open(deffile).read() |