From: Eric Anholt Date: Wed, 26 Feb 2020 00:25:05 +0000 (-0800) Subject: freedreno/computerator: Fix defined-but-not-used warnings from lex/yacc. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ec2f905ca8fda0deaba4fa099a9e47028c11d7e9;p=mesa.git freedreno/computerator: Fix defined-but-not-used warnings from lex/yacc. Tested-by: Marge Bot Part-of: --- diff --git a/src/freedreno/computerator/ir3_lexer.l b/src/freedreno/computerator/ir3_lexer.l index d93b892808f..ce2fb70b3d9 100644 --- a/src/freedreno/computerator/ir3_lexer.l +++ b/src/freedreno/computerator/ir3_lexer.l @@ -26,6 +26,8 @@ #include "ir3/ir3.h" #include "ir3_parser.h" +#define YY_NO_INPUT +#define YY_NO_UNPUT #define TOKEN(t) (ir3_yylval.tok = t) extern YYSTYPE ir3_yylval; diff --git a/src/freedreno/computerator/ir3_parser.y b/src/freedreno/computerator/ir3_parser.y index 93821b84f2b..f98233e9609 100644 --- a/src/freedreno/computerator/ir3_parser.y +++ b/src/freedreno/computerator/ir3_parser.y @@ -222,12 +222,14 @@ struct ir3 * ir3_parse(struct ir3_kernel *k, FILE *f) } %{ +#if YYDEBUG static void print_token(FILE *file, int type, YYSTYPE value) { fprintf(file, "\ntype: %d\n", type); } #define YYPRINT(file, type, value) print_token(file, type, value) +#endif %} %token T_INT