Add comments to clarify how #define gets wrapped

It took me a while to fully get my head around this, and I'd like to
help out future developers.
This commit is contained in:
Olly Betts 2022-07-27 08:52:33 +12:00
commit 36310c04e5
3 changed files with 11 additions and 0 deletions

View file

@ -10,6 +10,11 @@
*
* Integer arithmetic expression evaluator used to handle expressions
* encountered during preprocessing.
*
* Note that this is used for expressions in `#if` and the like, but not
* for expressions in `#define` which SWIG wraps as constants - for those
* we inject a `%constant` directive which is handled by the parser in
* `Source/CParse/parser.y`.
* ----------------------------------------------------------------------------- */
#include "swig.h"