GNOME Bugzilla – Bug 515052
gio:G_GNUC_FUNCTION is better than __FUNCTION__
Last modified: 2008-02-10 05:21:58 UTC
Please describe the problem: > 2008-01-27 Matthias Clasen <mclasen@redhat.com> > > * gbufferedinputstream.c: > * ginputstream.c: > * goutputstream.c: Replace uses of G_GNUC_PRETTY_FUNCTION by > __FUNCTION__. G_GNUC_PRETTY_FUNCTION was replaced by __FUNCTION__. But __FUNCTION__ may not be defined by the old compiler. If using __FUNCTION__, please use G_GNUC_FUNCTION. G_GNUC_FUNCTION is defined suitably in gmacros.h. Steps to reproduce: 1. compile by old compiler. Actual results: An error occurs. Expected results: Replace __FUNCTION__ by G_GNUC_FUNCTION. Does this happen every time? Revision 6389 or later Other information:
Using G_GNUC_FUNCTION is wrong and deprecated; use G_STRFUNC.
Created attachment 104713 [details] [review] patch for replacing __FUNCTION__ As you say. I missed that G_GNUC_FUNCTION was deprecated with G_GNUC_PRETTY_FUNCTION. We should use G_STRFUNC. This patch is replacing __FUNCTION__ by G_STRFUNC.
Thanks, looks fine to commit.
This has been fixed.