From: Jim Blandy <jimb@redhat.com>
To: Andrew Cagney <ac131313@redhat.com>
Cc: gdb@sources.redhat.com
Subject: Headers including other headers?
Date: Sat, 23 Feb 2002 09:23:00 -0000 [thread overview]
Message-ID: <20020223172336.372F05E9DE@zwingli.cygnus.com> (raw)
Suppose a header file in gdb/ contains code cannot be compiled without
definitions from other header files --- it uses typedefs, structures
in a way that requires their size, etc. Is it more proper for the
header file to #include the other headers it requires itself, or
should it be the responsibility of the .c file #including it to also
bring in its prerequisites?
In hopes that this doesn't start a really long thread of unsatisfying
disagreements: I personally think that this is not a matter of huge
consequence either way, but it's nicer to have a consistent pattern,
so having someone simply establish any reasonable guideline is more
important than the actual details of that guideline.
I'm not volunteering to convert our existing headers; I just want to
know what style is recommended for new header files.
next reply other threads:[~2002-02-23 17:23 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-02-23 9:23 Jim Blandy [this message]
2002-02-23 9:56 ` Andrew Cagney
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=20020223172336.372F05E9DE@zwingli.cygnus.com \
--to=jimb@redhat.com \
--cc=ac131313@redhat.com \
--cc=gdb@sources.redhat.com \
/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