This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, fixincludes] Fix NULL on AIX
- From: David Edelsohn <dje dot gcc at gmail dot com>
- To: Bruce Korb <bkorb at gnu dot org>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>, Mike Stump <mikestump at comcast dot net>
- Date: Tue, 30 Apr 2013 13:43:24 -0400
- Subject: Re: [PATCH, fixincludes] Fix NULL on AIX
- References: <CAGWvny=3PiUFQQwNKpAxTX1G1tXB8HfoOUwkmRpvdi2WyKhAXg at mail dot gmail dot com> <CAKRnqNJGh8mWOPWNVveT1J43MvO+pePG2LDPO+yRHHHw1qXb8w at mail dot gmail dot com> <CAGWvnykUyapsTusRaKimsDkPET1zk9MSXtLCqxDyLbsMD68iTg at mail dot gmail dot com> <CAKRnqNKv_7JY81nFA7sc0iX0LxdPyLjKGq4yW_yBssmV52_hmA at mail dot gmail dot com>
On Tue, Apr 30, 2013 at 1:09 PM, Bruce Korb <bkorb@gnu.org> wrote:
> By analogy, I'd prefer the EOF version there, too. But ultimately,
> it works and is not exactly illegible, so I have no serious objection
> to the fix. It would be nice if it were combinable, but doing so is
> tricky. I'm guessing that the fix on AIX is separated because the
> headers contain "__cplusplus" and that is used as an exclusion test
> for the "void_null" fix? Otherwise this:
>
> select = "^#[ \t]*define[ \t]+NULL[ \t]+("
> "\\(\\(void[ \t]*\\*\\)0\\)" "|" "\\(*0L*\\)*" ")";
>
> would allow void_null to work for you -- perhaps by using %1 somewhere
> in the replacement "c-fix-arg".
Yes, I created a separate fix because the void_null fix has additional
selection details that I did not want to change and possibly break
other platforms.
Thanks, David