C_PP

A program for testing C preprocessor directives
Download

C_PP Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Freeware
  • Publisher Name:
  • TextTransformer
  • Operating Systems:
  • Windows All
  • File Size:
  • 662 KB

C_PP Tags


C_PP Description

The C_PP application was designed to be a program for testing C preprocessor directives. You can replace the text in the upper window with c/c++ code. As examples a lot of macros are listed in the combobox. If you execute the preprocessor then with the button in the toolbar, the preprocessed text appears in the lower output window. C++ files can be remodeled into the preprocessed form with c_pp, like they are "seen" by the compiler: Preprocessor directives are removed, include files are included, definitions are replaced, not defined areas are removed and macros are expanded. In contrast to existing preprocessors of the different compiler manufacturers, c_pp does not only create an intermediate sequence of tokens, but a real text. The name "c_pp" stands for C-preprocessor. The underscore distinguishes the name from a Cplusplus parser also existing with the name "Cpp". The original version of this C++ preprocessor was developed to prepare the translation of a company software written in C++ into Java. So it wasn't the aim to produce a general preprocessor, which copes with all possible tricks of preprocessor Meta programming. The aim was rather pragmatic: The preprocessor directives should be replaced from the finite number of files in a way which maintained the meaning of these directives. - "real" C++ constants were inserted in the code for defined constants - quite a number of macros were not resolved but replaced by functions - comments were left in the code - headers of the system files and library files were not included. Their contents should be substituted by their java analoga directly. - for every company header a corresponding preprocessed header was produced and the include directives for these headers therefore were left in the source code. These special treatments tailored to the company software in question, were removed from the c_pp project published here. However, it is easily possible to insert corresponding special treatments for other translation projects once more again.


C_PP Related Software