/P, /E and /PE preprocesses a source file only (without compling it into an object file). Start #define NUM 42 The number is NUM #ifdef NUM It is defined #else It is not defined #endif The end
cl /P file.c creates file.i with the following content: #line 1 "file.c" Start The number is 42 It is defined #line 9 "file.c" The end
cl /E file.c prints the (same) preprocessed result to stdout. cl /EP file.c also writes the preprocessed result to stdout and it also removes the #line directives: Start The number is 42 It is defined The end