summaryrefslogtreecommitdiff
path: root/tools/generate.c
diff options
context:
space:
mode:
authorTommi Komulainen <tommi.komulainen@iki.fi>2008-10-12 21:07:39 +0000
committerTommi Komulainen <tko@src.gnome.org>2008-10-12 21:07:39 +0000
commit4f0e31e258ce34ebab6cb1ce482fa79001e06bbd (patch)
tree80fb554391a09984a75e3e432803c74aa36f247f /tools/generate.c
parent5858b453e1f983afd3434278bf6ce0758f5b6919 (diff)
downloadgobject-introspection-4f0e31e258ce34ebab6cb1ce482fa79001e06bbd.tar.gz
move "transfer" and "null-ok" attributes from <function> to <return-value>
2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi> * tools/generate.c (write_callable_info): move "transfer" and "null-ok" attributes from <function> to <return-value> element svn path=/trunk/; revision=691
Diffstat (limited to 'tools/generate.c')
-rw-r--r--tools/generate.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/generate.c b/tools/generate.c
index 8e25d33d..04cb87c4 100644
--- a/tools/generate.c
+++ b/tools/generate.c
@@ -239,6 +239,10 @@ write_callable_info (const gchar *namespace,
type = g_callable_info_get_return_type (info);
+ g_fprintf (file, ">\n");
+
+ g_fprintf (file, "%*s <return-value", indent, "");
+
if (g_type_info_is_pointer (type))
{
switch (g_callable_info_get_caller_owns (info))
@@ -255,14 +259,12 @@ write_callable_info (const gchar *namespace,
g_assert_not_reached ();
}
}
-
- g_fprintf (file, ">\n");
-
- g_fprintf (file, "%*s <return-value>\n", indent, "");
if (g_callable_info_may_return_null (info))
g_fprintf (file, " null-ok=\"1\"");
+ g_fprintf (file, ">\n");
+
g_fprintf (file, "%*s <type name=\"", indent + 2, "");
write_type_info (namespace, type, file);