revCPP A reversible C++ preprocessor
- Benoît Sigoure, Quentin Hocquet
- revCPP, unCPP, CPP, C++, Transformers, program transformation, _N_ C preprocessor, C++ preprocessor
Abstract: The Transformers project aims at creating a generic framework for C++ source to source transformation. Source to source transformation consists in refactoring the code and producing a modified source. The resulting code may be reread, reused, re-modified ...by programmers and thus must be human-readable. Moreover it should respect the original coding style. This process of preserving the original layout is called high fidelity program transformation. Transformers targets the C/C++ language. Unlike many other languages, C++ source code is preprocessed to obtain the actual source code. In our program transformation context we need to un-preprocess the code to give back a human-readable code to the programmer. This document presents the work and research carried out to implement a reversible C++ preprocessor and a postprocessor, i.e. a tool to obtain the original code from the preprocessed one.