After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 580300 - gtkdoc-scan picks up _get_type functions it should not
gtkdoc-scan picks up _get_type functions it should not
Status: RESOLVED FIXED
Product: gtk-doc
Classification: Platform
Component: general
unspecified
Other All
: Normal normal
: 1.12
Assigned To: gtk-doc maintainers
gtk-doc maintainers
Depends on:
Blocks:
 
 
Reported: 2009-04-26 15:01 UTC by Morten Welinder
Modified: 2009-06-27 19:55 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Morten Welinder 2009-04-26 15:01:19 UTC
gtkdoc-scan should not pick up this function because it takes arguments.
It's clearly not defining a GObject type.

GType go_conf_get_type (GOConfNode *node, gchar const *key);
Comment 1 Morten Welinder 2009-04-26 15:06:26 UTC
Version 1.10 as reported with "--version".

gtkdoc-scangobj makes assumptions on arguments as well as
return type:

    for (@types) {
	print OUTPUT "extern GType $_ (void);\n";
    }
Comment 2 Stefan Sauer (gstreamer, gtkdoc dev) 2009-04-26 16:10:39 UTC
Its know fact that gtkdoc-scan --rebuild-types has limmitations. It only works if you follow GObject conventions. But I agree that more smartness would be useful here. Would you be willing to try to make a patch?
Comment 3 Stefan Sauer (gstreamer, gtkdoc dev) 2009-06-27 19:55:15 UTC
Apparently you've been not so much worried to try to fix it. Also you analysis was a bit off. gtkdoc-scangobj makes no assumtions, you simply shall not put crap into the types file. I made gtkdoc-scan that offers to write a types file for you a bit smarter though to adhere to the rules too :)

commit 613e1f7dca2ccb1cbe95386070e94ba0c41cddf8
Author: Stefan Kost <ensonic@users.sf.net>
Date:   Sat Jun 27 22:46:11 2009 +0300

    scan: be smarter in when trying to figure the get_type functions, Fixes #580300
    
    Check full prototype instead of just the name when using --rebuild-types. Also
    sort the types by name to minimize the delta when rebuilding.