GNOME Bugzilla – Bug 742501
macro _VTE_GNUC_NONNULL causing gtk-doc to drop last argument in reference
Last modified: 2015-04-08 18:43:20 UTC
In the VTE function reference, the last argument is missing in the quoted function signature for most functions - see e.g. https://developer.gnome.org/vte/0.38/VteTerminal.html Similarly for the current unstable. The affected functions are those whose prototype is followed by _VTE_GNUC_NONNULL(...). This macro requires --ignore-decorators='_VTE_GNUC_NONNULL\s*\([^)]*\)' to be added to SCAN_OPTIONS. Even then, gtk-doc <= 1.21 will ignore the last argument where this macro does not occur just once. See https://bugzilla.gnome.org/show_bug.cgi?id=741941 According to GLib's README.rationale , such a non-null macro should not be used in favour of the introspection annotations. Therefore, it may make sense to eliminate the macro _VTE_GNUC_NONNULL and its references.
Thanks for this report! I submitted a quick fix (which requires a fixed gtk-doc -- bug 741941 comment 5 clearly points out that gtk-doc was buggy so far and just got fixed; I have no desire to work around that bug). I think we should leave this bug open to replace attributes by annotations if that's indeed superior.
Annotations are for docs, the attributes are for the compiler. IMO glib is wrong not to add those attributes (see https://bugzilla.gnome.org/show_bug.cgi?id=113075#c46 ), so I'm not going to remove them.
Changing resolution since the bug is actually fixed. :)
*** Bug 747466 has been marked as a duplicate of this bug. ***