From: Andrew Morton <akpm@zip.com.au>
To: Rasmus Andersen <rasmus@jaquet.dk>
Cc: linux-kernel@vger.kernel.org
Subject: Re: __func__ in 2.5.33?
Date: Tue, 03 Sep 2002 14:48:40 -0700 [thread overview]
Message-ID: <3D752E38.EF352F48@zip.com.au> (raw)
In-Reply-To: 20020903225229.A24108@jaquet.dk
Rasmus Andersen wrote:
>
> Hi,
>
> I trying to compile the SX driver for the 2.5.33 kernel, I got a
> lot of warnings looking like (this is from a test program, not
> the driver itself)
>
> test.c: In function `main':
> test.c:6: called object is not a function
> test.c:6: parse error before string constant
>
> This seems to stem from the recent __FUNCTION__ vs. __func__
> change in kernel.h and the SX driver's use of __FUNCTION__ in the
> following construct
>
> #define func_enter() sx_dprintk (SX_DEBUG_FLOW, "sx: enter " __FUNCTION__ "\n")
>
The parenthesised (__func__) is there to force you to not try to
perform this string pasting. Support for __FUNCTION__ pasting is
being phased out of gcc.
You need:
#define func_enter() sx_dprintk (SX_DEBUG_FLOW, "sx: enter %s\n", __FUNCTION__)
next prev parent reply other threads:[~2002-09-03 21:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-09-03 20:52 __func__ in 2.5.33? Rasmus Andersen
2002-09-03 21:48 ` Andrew Morton [this message]
2002-09-04 6:34 ` Rasmus Andersen
-- strict thread matches above, loose matches on Subject: below --
2002-09-03 22:03 Paul Larson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3D752E38.EF352F48@zip.com.au \
--to=akpm@zip.com.au \
--cc=linux-kernel@vger.kernel.org \
--cc=rasmus@jaquet.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox