glcpp: Fix function-like macros with an argument used multiple times.
It's really hard to believe that this case has been broken, but apparently no test previously exercised it. So this commit adds such a test and fixes it by making a copy of the argument token-list before expanding it. This fix causes the following glean tests to now pass: glsl1-Preprocessor test 6 (#if 0, #define macro) glsl1-Preprocessor test 7 (multi-line #define)
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
#define double(x) x x
|
||||
double(1)
|
||||
Reference in New Issue
Block a user