The pre-processor sits between your program source file and the compiler.

It can act as a kind of filter, responding to directives in your program, and doing things to the program source before the compiler sees it. The pre-processor detects directives by the fact that they start with a # character.

The diagram on the right shows how the pre-processor fits in.

C is one of the few high level languages which provides a pre-processor, although they are common in assemblers.

 


Program source to assembler output flow chart