Re: problems with deprecation of struct members



Hi,

Matthias Clasen schrieb:
> I am having issues getting gtk-doc 1.9 to produce complete gtk+ docs for me.
> The 2.12.2 release I did yesterday contains a pretty incomplete set of gtk docs,
> unfortunately.
> 
> The issue seems to be this field in the _GtkToolbar struct:
> 
> 
> #ifndef GTK_DISABLE_DEPRECATED
>   GtkTooltips     *tooltips;
> #else
>   gpointer        _tooltips;
> #endif
>

Hmm, this is not easy to fix. The parse is not smart enough to allow deprecating
single parts (like arguments in a function). I'll try very hard to have a
gtk-doc day this week and then I see if it can be handled. Practically gtk-doc
would need some special casing for this, as in the docs we just would like to
show some grayed
  GtkTooltips     *tooltips; /* deprecated */
and not an #ifdef ... #endif

Stefan

> 
> 
> When I have that in the headers, I get the following from gtkdoc-scan:
> 
> Cannot parse structure field "}" in struct _GtkToolbar
> 
> After patching the message to dump out the whole $declaration as well,
> I get:
> 
> {
>   gint             num_children;
>   GList           *children;
>   GtkOrientation   orientation;
>   GtkToolbarStyle  style;
>   GtkIconSize      icon_size;
> 
> #ifndef GTK_DISABLE_DEPRECATED
>   GtkTooltips     *tooltips;
> #else
>   gpointer        _tooltips;
> #endif
> };
> 
> 
> Notice how it thinks the struct ends after the ifdef, when in fact it doesn't.
> 
> I first thought this was due to the #else, but when I replace it with
> 
> #ifndef GTK_DISABLE_DEPRECATED
>   GtkTooltips     *tooltips;
> #endif
> 
> I still get the same error.
> 
> I'd like to build a 2.12.3 with complete docs, but I need to have a gtk-doc fix
> before I can do so....
> 
> 
> Matthias
> _______________________________________________
> gtk-doc-list mailing list
> gtk-doc-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtk-doc-list



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]