Empty source file

Karl Botts kdb at chinet.chi.il.us
Sun Oct 15 18:25:43 AEST 1989


In article <10955 at riks.csl.sony.co.jp> diamond at ws.sony.junet (Norman Diamond) writes:
>The grammar given in the standard does not permit an empty source
>file.  Strangely enough, a preprocessor source file may be empty,

Are you sure this is true; I find it hard to believe.  It is quite
reasonable and not uncommon to have source files which are empty after the
preoprocessor gets done with them.  I have had such in the past, and have
explicitly tested it on xeveral compilers, and empty source files do
compile to do-nothing objects, which seems right to me.

Maybe you are thinking of an empty program, which is of course illegal; the
address of main() must be resolved somehow.



More information about the Comp.std.c mailing list