diff options
author | Colin Walters <walters@src.gnome.org> | 2008-09-16 19:44:26 +0000 |
---|---|---|
committer | Colin Walters <walters@src.gnome.org> | 2008-09-16 19:44:26 +0000 |
commit | 8a30e26ca10eeaa2dbbd21fcea99b092ff69706a (patch) | |
tree | 2f9fa23e0fb1ee7b48aa8ecfd24e4f568632a1db /tools/generate.c | |
parent | e89b29b5fd5bd692c150a49f2779fa2963a334c0 (diff) | |
download | gobject-introspection-8a30e26ca10eeaa2dbbd21fcea99b092ff69706a.tar.gz |
Print out "any" for VOID+pointer, not "none"
* tools/generate.c: Print out "any" for VOID+pointer,
not "none"
svn path=/trunk/; revision=610
Diffstat (limited to 'tools/generate.c')
-rw-r--r-- | tools/generate.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/tools/generate.c b/tools/generate.c index efa4e7a7..c63acdcc 100644 --- a/tools/generate.c +++ b/tools/generate.c @@ -52,6 +52,7 @@ write_type_info (const gchar *namespace, gint tag; gint i; GITypeInfo *type; + gboolean is_pointer; const gchar* basic[] = { "none", @@ -77,8 +78,14 @@ write_type_info (const gchar *namespace, }; tag = g_type_info_get_tag (info); - - if (tag < 20) + is_pointer = g_type_info_is_pointer (info); + + if (tag == GI_TYPE_TAG_VOID) { + if (is_pointer) + g_fprintf (file, "%s", "any"); + else + g_fprintf (file, "%s", "none"); + } else if (tag < 20) g_fprintf (file, "%s", basic[tag]); else if (tag == 20) { |