[prog] [C/C++] what to put in header files.
Laurel Fan
laurel at sdf.lonestar.org
Wed Sep 25 13:49:23 EST 2002
On Wed, Sep 25, 2002 at 10:27:43AM +0200, Dan Richter wrote:
> Sometimes at the beginning teachers tell students to write header files
> like this:
>
> #ifndef FOO_H
> #define FOO_H
>
> /* Interface stuff here. */
>
> #include "foo.c"
> #endif
I don't get it... how is that simpler than
foo.h:
#ifndef FOO_H
#define FOO_H
/* Interface stuff here. */
#endif
foo.c:
#include "foo.h"
?
--
laurel at sdf.lonestar.org
http://dreadnought.gorgorg.org
More information about the Programming
mailing list