[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: pfctl.c -> header file
On Sat, Mar 09, 2002 at 06:01:02AM -0300, Martin Marconcini wrote:
> However, it has always been C++, not C. My question is: Why pfctl.c has all
> the function prototypes at the beginning, instead of having an include of
> the header file pfctl.h? (I understand C does not require func. prototypes
> and they are optional?)
> Is there any particular reason for not having a .h file?
See style(9). All functions should be prototyped somewhere, and if the
functions are local to one source module, that's done at the top of the
source file. A header file is only used if it's included by more than
one source file.