summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2010-01-11 15:27:35 +0000
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2010-01-11 15:28:23 +0000
commit02d6ca0ff7a19f47b7367eda756a4d5121135b11 (patch)
tree077f8da9c448458876fb983e96d0fd8bec264de2
parent0ce9468ed9a70c4ee2a1e88add54fb058e7c4356 (diff)
Sync glib-ginterface-gen.py from telepathy-glib, fixing method names that are C keywords
This is commit 46dc86715c3ff6b0e from telepathy-glib. Reviewed-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
-rw-r--r--tools/glib-ginterface-gen.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/glib-ginterface-gen.py b/tools/glib-ginterface-gen.py
index 13f7f69e..95c827c7 100644
--- a/tools/glib-ginterface-gen.py
+++ b/tools/glib-ginterface-gen.py
@@ -418,7 +418,7 @@ class Generator(object):
stub_name = (self.prefix_ + self.node_name_lc + '_' +
class_member_name)
- return (stub_name + '_impl', class_member_name)
+ return (stub_name + '_impl', class_member_name + '_cb')
def do_method(self, method):
assert self.node_name_mixed is not None
@@ -506,7 +506,7 @@ class Generator(object):
self.b(' %s%s,' % (ctype, name))
self.b(' DBusGMethodInvocation *context)')
self.b('{')
- self.b(' %s impl = (%s%s_GET_CLASS (self)->%s);'
+ self.b(' %s impl = (%s%s_GET_CLASS (self)->%s_cb);'
% (impl_name, self.PREFIX_, self.node_name_uc, class_member_name))
self.b('')
self.b(' if (impl != NULL)')
@@ -550,7 +550,7 @@ class Generator(object):
% (self.prefix_, self.node_name_lc, class_member_name,
self.Prefix, self.node_name_mixed, impl_name))
self.b('{')
- self.b(' klass->%s = impl;' % class_member_name)
+ self.b(' klass->%s_cb = impl;' % class_member_name)
self.b('}')
self.b('')