parser: add a workaround for byacc Unlike bison, byacc outputs its own parser code *after* our own parser.y code, which includes the #undef. So this fix is needed for the 'scanner' -> 'param->scanner' translation to work in the parser.c code generated by byacc. Signed-off-by: Ran Benita <ran234@gmail.com>
diff --git a/src/xkbcomp/parser.y b/src/xkbcomp/parser.y
index 8b3ca5b..bb4be7b 100644
--- a/src/xkbcomp/parser.y
+++ b/src/xkbcomp/parser.y
@@ -798,3 +798,5 @@ parse(struct xkb_context *ctx, void *scanner, const char *map)
return first;
}
+
+#define scanner param->scanner