Ace: a syntax-driven C preprocessor (1989) [pdf]
swtch.com
swtch.com
My personal bottom line: Better stick to the language canon and switch the complete infrastructure then only parts of it, except it is a small developer group or exceptional documentation.
That's nice, but you cannot do that in Fortran without that perl script, so apples and oranges.
That perl script cannot possibly be a worse dependency containing more technical debt than C++.
Way back as an undergrad student, I suspected this, after successfuly implementing the rendering of hyperbolic (y = A/x) curves with Bresenham. It hit me; that /x could be the perspective divide by z; that vertical coordinate could be marching through texture space. Never tried it, though.
If you're going to preprocess C code then you should use something which is aware of the syntax of C (analogous to camlp4 for OCaml). There are a bunch of "LISP macro for C" projects out there.