2 ms·
Yeah, the enumerations require the preprocessor to understand the language and process the struct definitions... which may not even exist yet if they contain ma
by eqvinox 5y ago
Yeah, the enumerations require the preprocessor to understand the language and process the struct definitions... which may not even exist yet if they contain macros :D.
It's not an easy problem. Generating some kind of macro-usable list like you suggest is probably the way to go, essentially making the entire thing a 2-pass process. (That said, the C preprocessor doesn't have a concept of "lists", perhaps that's the thing to actually add here.)