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 790829 - glib-genmarshal --body must not generate alias implementations
glib-genmarshal --body must not generate alias implementations
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: gobject
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
: 791852 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2017-11-25 20:22 UTC by Tim Janik
Modified: 2017-12-21 16:59 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Do not generate marshaller aliases in source files (2.70 KB, patch)
2017-11-28 15:06 UTC, Emmanuele Bassi (:ebassi)
committed Details | Review

Description Tim Janik 2017-11-25 20:22:17 UTC
Calling 'glib-genmarshal --body' must not generate a function body implementation for a stdinc alias generated by 'glib-genmarshal --header'.
Example:

$ cat x.list
VOID:POINTER

$ glib-genmarshal x.list --header   # OK, using stdinc
#define g_cclosure_user_marshal_VOID__POINTER	g_cclosure_marshal_VOID__POINTER

$ glib-genmarshal x.list --body # WRONGLY generates body for alias
g_cclosure_user_marshal_VOID__POINTER (GClosure     *closure,
Comment 1 Emmanuele Bassi (:ebassi) 2017-11-28 15:06:15 UTC
Created attachment 364569 [details] [review]
Do not generate marshaller aliases in source files

When generating the body of the marshallers, we need to skip aliases to
standard marshallers provided by GLib itself.
Comment 2 Philip Withnall 2017-11-28 15:19:24 UTC
Review of attachment 364569 [details] [review]:

Yes.

As discussed on IRC, having some regression tests for this (and glib-mkenums) would be most awesome. But this can go in already.
Comment 3 Philip Withnall 2017-11-28 15:20:21 UTC
As you also mentioned on IRC, this probably should also be backported to glib-2-54 (plus any other glib-genmarshal/glib-mkenums fixes which have slipped in without being backported).
Comment 4 Emmanuele Bassi (:ebassi) 2017-12-21 13:54:50 UTC
Attachment 364569 [details] pushed as bf0be21 - Do not generate marshaller aliases in source files
Comment 5 Emmanuele Bassi (:ebassi) 2017-12-21 16:59:32 UTC
*** Bug 791852 has been marked as a duplicate of this bug. ***