summaryrefslogtreecommitdiff
path: root/giscanner/girwriter.py
diff options
context:
space:
mode:
authorJohan Dahlin <jdahlin@async.com.br>2009-01-20 20:41:52 +0000
committerJohan Dahlin <johan@src.gnome.org>2009-01-20 20:41:52 +0000
commite6b0f3b11a2d00dc17d7f928ef94b4c3f610d499 (patch)
tree85eaaae8df6e3fb841adf348b11c6f3b2b9be64a /giscanner/girwriter.py
parentb8079c4098c2dbfc6f8aa607eefb4f53e59b04e6 (diff)
downloadgobject-introspection-e6b0f3b11a2d00dc17d7f928ef94b4c3f610d499.tar.gz
Bug 562615 – Struct methods missing
2009-01-20 Johan Dahlin <jdahlin@async.com.br> Bug 562615 – Struct methods missing * giscanner/annotationparser.py: * giscanner/ast.py: * giscanner/girwriter.py: * giscanner/glibast.py: * giscanner/glibtransformer.py: * tests/scanner/foo-1.0-expected.gir: * tests/scanner/foo-1.0-expected.tgir: svn path=/trunk/; revision=1054
Diffstat (limited to 'giscanner/girwriter.py')
-rw-r--r--giscanner/girwriter.py23
1 files changed, 12 insertions, 11 deletions
diff --git a/giscanner/girwriter.py b/giscanner/girwriter.py
index 39d7c22e..89af8fb9 100644
--- a/giscanner/girwriter.py
+++ b/giscanner/girwriter.py
@@ -323,7 +323,10 @@ and/or use gtk-doc annotations. ''')
attrs.append(('doc', boxed.doc))
attrs.extend(self._boxed_attrs(boxed))
with self.tagcontext('glib:boxed', attrs):
- self._write_boxed_ctors_methods(boxed)
+ for method in boxed.constructors:
+ self._write_constructor(method)
+ for method in boxed.methods:
+ self._write_method(method)
def _write_property(self, prop):
attrs = [('name', prop.name)]
@@ -359,12 +362,6 @@ and/or use gtk-doc annotations. ''')
return [('glib:type-name', boxed.type_name),
('glib:get-type', boxed.get_type)]
- def _write_boxed_ctors_methods(self, boxed):
- for method in boxed.constructors:
- self._write_constructor(method)
- for method in boxed.methods:
- self._write_method(method)
-
def _write_record(self, record):
attrs = [('name', record.name),
('c:type', record.symbol)]
@@ -380,8 +377,10 @@ and/or use gtk-doc annotations. ''')
if record.fields:
for field in record.fields:
self._write_field(field)
- if isinstance(record, GLibBoxed):
- self._write_boxed_ctors_methods(record)
+ for method in record.constructors:
+ self._write_constructor(method)
+ for method in record.methods:
+ self._write_method(method)
def _write_union(self, union):
attrs = [('name', union.name),
@@ -396,8 +395,10 @@ and/or use gtk-doc annotations. ''')
if union.fields:
for field in union.fields:
self._write_field(field)
- if isinstance(union, GLibBoxed):
- self._write_boxed_ctors_methods(union)
+ for method in union.constructors:
+ self._write_constructor(method)
+ for method in union.methods:
+ self._write_method(method)
def _write_field(self, field):
if isinstance(field, Function):