Lattice/UNIX incompatibility
Lauren Weinstein
lauren at vortex.UUCP
Wed Jan 2 17:05:30 AEST 1985
I use C86 here. It also enforces the external declarations in a manner
that, on the surface, makes multiple file include files difficult to
manage. However, there is a simple solution, which, while not
fancy, is fully compatible with all other compilers that I know of.
In the .h file to be included among various files, I add:
EXTERN
before each declaration.
Then, in one (usually the first) of my source files, I put
#define EXTERN
at the top, then
#define EXTERN extern
at the top of all the other source files. This effectively takes
care of the problem, and lets me manage my .h files with a minimum
of hassle, under the circumstances.
--Lauren--
More information about the Comp.lang.c
mailing list