C preprocessor tricks, tips, and idioms (2015)

Pete_D | 78 points

I used to use all sorts of preprocessor tricks in my C code. I eventually made an effort to eliminated all preprocessor use in the code (except for #include, where there was no alternative).

The result was surprisingly pleasing. The code looked much nicer without all the #'s breaking up the indentation, and it made C look like a more modern language :-)

WalterBright | 5 years ago

There are lots of horrific weapons like this to ever torment the universe. e.g. http://p99.gforge.inria.fr/p99-html/index.html

sigjuice | 5 years ago