This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Quotes and Brackets In Include Directives
- To: Eric Lemings <eric dot b dot lemings at lmco dot com>
- Subject: Re: Quotes and Brackets In Include Directives
- From: Tim Hollebeek <tim at hollebeek dot com>
- Date: Tue, 4 Sep 2001 18:26:28 -0400
- Cc: gcc at gnu dot org
- References: <3B952FB8.2AD2B6C8@lmco.com>
- Reply-To: tim at hollebeek dot com
> I always thought that:
>
> #include <string.h>
>
> would include the string.h header in the "system" include path while:
>
> #include "string.h"
>
> would include a different string.h header file in the "local" include
> path.
You thought wrong. The relevant standards have always mandated that
the "" search list be a superset of the <> include search list.
Order is, IIRC, implementation defined.
In particular, this means that having local include files with names
that are the same as system headers is asking for trouble. Various
compilers can and do differ in which one you will get with various
combinations of CWD, -I options, etc.
-Tim