From: Joel Brobecker <brobecker@adacore.com>
To: Bruno Haible <bruno@clisp.org>
Cc: Daniel Jacobowitz <drow@false.org>,
bug-gnulib@gnu.org, gdb-patches@sourceware.org
Subject: Re: [RFC] Use gnulib's stdint.h.
Date: Tue, 01 Jul 2008 00:28:00 -0000 [thread overview]
Message-ID: <20080701002808.GA1390@adacore.com> (raw)
In-Reply-To: <200806280259.26427.bruno@clisp.org>
Hi Bruno,
> > > 2. ctype/safe-ctype conflict. For instance, cp-support.c includes
> > > safe-ctype.h. But at the same time, we previously included
> > > defs.h, which itself includes gnulib/stdint.h, which includes
> > > <wchar.h> which includes <ctypes.h>.
> >
> > > Problem #2 is a lot more problematic, however. I might argue that
> > > this is a actually bug inside gnulib and that gnulib/stdint.h
> > > should be generated in a way that avoids including other standard
> > > header files.
>
> No. gnulib makes no guarantee that particular headers or symbols are
> not defined.
I wasn't really suggesting that gnulib should make a general guaranty,
but if the wchar.h include could easily be avoided, then it would have
made GDB's life a little easier. It was worth asking :)
> 3. In those places where gnulib could control these extra #includes,
> the price would be sets of #ifdefs that would be too clumsy to be
> maintainable.
I see your point.
> The bug is in safe-ctype.h:
>
> #ifdef isalpha
> #error "safe-ctype.h and ctype.h may not be used simultaneously"
> #endif
>
> Actually I don't see the reason for this #error: safe-ctype.h defines only
> uppercase-named macros, and <ctype.h> defines only lowercase-named or
> underscore-prefixed macros.
I will see with the GCC maintainers what they think. Maybe the check
made better sense at one point, but no longer makes sense today.
I checked the public history of that file and version 1 of that file
(dated circa 2000) already defines the macros in uppercase and
has the isalpha macro check.
--
Joel
prev parent reply other threads:[~2008-07-01 0:28 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-05 18:41 Daniel Jacobowitz
2008-06-26 15:58 ` Daniel Jacobowitz
2008-06-27 19:31 ` Joel Brobecker
2008-06-27 19:37 ` Daniel Jacobowitz
2008-06-27 19:57 ` Joel Brobecker
2008-07-04 17:59 ` Joel Brobecker
2008-06-28 7:10 ` Bruno Haible
2008-07-01 0:28 ` Joel Brobecker [this message]
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=20080701002808.GA1390@adacore.com \
--to=brobecker@adacore.com \
--cc=bruno@clisp.org \
--cc=bug-gnulib@gnu.org \
--cc=drow@false.org \
--cc=gdb-patches@sourceware.org \
/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