shecc
shecc copied to clipboard
Unable to parse the specific macros
With the discussion in the pull request (#140) , we found that shecc cannot deal with macros containing assignment and compound assignment operators.
Here are the examples:
#define MACRO1(variable, val) \
variable = variable + val + 10
#define MACRO2(variable, val) \
variable += val + 10
By GCC or Clang, the above macros will be expanded and perform the operations, but shecc cannot parse them correctly.
Therefore, the lexer/parser must be improved to handle macros like these examples.