This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: system.h
- To: jfc at mit dot edu
- Subject: Re: system.h
- From: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- Date: Tue, 17 Feb 1998 11:19:22 -0500 (EST)
- Cc: egcs at cygnus dot com
> From: John Carr <jfc@MIT.EDU>
>
> > Maybe a good compromise is to split it into two files,
> > system.h and system2.h.
>
> That's better than testing a macro. I suggest different calling the
> files ansi.h and system.h (corresponding, more or less, to ANSI and
> POSIX interfaces).
John,
I don't know what particular system headers fall under the ANSI
category, but I'd rather base the primary includes on which ones are the
most requested by the egcs source, rather than which ones ANSI happens
to say are part of its spec. (They may happily coincide, But for this
reason I would shy away from calling the primary one ansi.h.)
If we don't based it on popularity, it'll be more likely we'll
get into the situation where too many source files include both common
headers. Then we've gained nothing by splitting them.
I'd like it if you would make a proposal of which headers you
would like to see in the primary common egcs header. I'm sure we can
reach a good compromise.
The following are the top ten system headers requested by the
egcs source code. I browsed the remaining implicit function declaration
warnings, stdlib.h and string.h would seem to be the ones which would
get included a bit more, but this remains a good point of reference.
--Kaveh
196 <stdio.h>
87 <stdlib.h>
56 <ctype.h>
55 <string.h>
31 <sys/types.h>
27 <unistd.h>
27 <errno.h>
24 <strings.h>
18 <time.h>
18 <stdarg.h>
--
Kaveh R. Ghazi Project Manager / Custom Development
ghazi@caip.rutgers.edu ICon CMT Corp.