Ignore unknown preprocessor directives which are inside an inactive

conditional (github issue #394, reported by Dan Wilcox).
Regression introduced in 3.0.3.
This commit is contained in:
Olly Betts 2015-04-30 13:40:42 +12:00
commit d26a505dad
3 changed files with 24 additions and 1 deletions

View file

@ -107,3 +107,18 @@ void another_macro_checking(void) {
bumpf(10);
}
%}
/* Check that unknown preprocessor directives are ignored inside an inactive
* conditional (github issue #394).
*/
#ifdef APPLE_OPENGL
# import <OpenGLES/ES1/gl.h>
#endif
#ifdef AAA
# define B
#else
# wibble wibble
#endif
#if 0
# wobble wobble
#endif