Define the c preprocessor, C/C++ Programming

Define the C Preprocessor?

Preprocessor' is a translation stage that is applied to your source code before the compiler proper gets its hands on it usually the preprocessor performs textual substitutions on your source code.

Module

Purpose

Pre-processor

Pre-process text for input to the compiler

Compiler

Compile pre-processed text into intermediate code

Code generator

Generate assembler code for a target machine

Assembler

Compile assembler code into object modules

Linker

Link object modules into executable code

1193_C Preprocessor.png

The pre-processor basically processes text; it knows virtually nothing about C syntax. It scans the input program text look for the directives in which the first character on a line is a '#'. While it convenes these directives, it takes certain actions including other files to be processed defining symbols, and so on it acts completely on the program text and will happily pre-process text which may be complete gibberish for the C compiler. This pre-processed text is after that passed on to the C compiler itself which checks the C syntax and if it consumes it, likes it, translating it into some intermediate code which is output, ready for input to the next phase.

Posted Date: 6/14/2013 2:02:03 AM | Location : United States







Related Discussions:- Define the c preprocessor, Assignment Help, Ask Question on Define the c preprocessor, Get Answer, Expert's Help, Define the c preprocessor Discussions

Write discussion on Define the c preprocessor
Your posts are moderated
Related Questions
Exceptions. Your SVector class should throw four exceptions: 3.1. If the constructor size is invalid, then it will just allow the implicit STL bad_alloc exception to pass up to mai

C program to demonstrate Pointer to variable: void p2a(int *); void main() {                 int x=10, *a,**b;                 int arr[5];                 //poin

how to create database of faculty database......... send me with program

how to convert a general tree into binary tree with example

Abstract Classes Abstract classes are the classes, which are written just to act as base classes. Consider the following classes.                 class base

how can i write reverse digit function like writing 1234 and printing 4321

What is  T y pe C a s t Op er a t o r :   T h e f l o a t c a n b e c o n v e r t e d t o i n t e g e r v a l u

write a program to calculate the cuboid

Described the differences among a C++ struct & C++ class? A: The default member & base class access specifies are distinct. It is one of the commonly misunderstood aspects of C+

A Network of routers have been configured for the purposes of handling data traffic within your company. You would like to have an application that does a network