I have some gripes with C, though I use it sometimes. Macros are one of them.
- They are hard to write as long as you use them for anything besides numeric constants, due to their horrible syntax
- They are even harder to debug, because the C preprocessor takes care of them BEFORE error detection begins its work
- They shouldn’t be needed. Macros are used for constants, functions with high performance constraints, and header protection. Constants should be declared the usual way (it works in C++, but not in C), high-performance functions should be inlined instead (works in C++, buggy in C99), and header protection should be a standard feature of the language
So in the last week-end, I tried to remove as much #defines from my code as I could, in order to make it cleaner and easier to debug. For some reason, this also resulted in my code compiling faster. The C preprocessor of GCC could be a bit slow.
Apart from that, well, I updated the doc to have it mirror the latest version of the code.