Source files are of two types:
- interface source files and
- implementation source files.
The interface source files are normally referred
to as header files normally have .h extension and implementation files have .c
extension.
The
interface files contain the function prototypes, variable declarations,
structure/union definitions etc.
The
implementation source files contain the information like function definitions,
other definitions and the information needed to generate the executable file,
allocate and initialize data.
The
standard header files are examples for the interface files and the code is
available as .lib files and are linked at link-time by the linker to generate
the .exe file. It should be noted that
only the code for the functions used in the program gets into the .exe file
even though many more functions are available in the header files.
No comments:
Post a Comment