X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmesa%2Fprogram%2Fprogram_lexer.l;h=0a50dab97fd4fd48e5d342febf1b16f98bf20bcd;hb=1b708d8f4dd1a853de8537e81e6d5bf8c9f2aed1;hp=5730c6d761b907bbba44f68dcc7ea8dbff3b3d2b;hpb=ca12aefdacd22fb42e3f1d3852db4c12de886554;p=mesa.git diff --git a/src/mesa/program/program_lexer.l b/src/mesa/program/program_lexer.l index 5730c6d761b..0a50dab97fd 100644 --- a/src/mesa/program/program_lexer.l +++ b/src/mesa/program/program_lexer.l @@ -139,7 +139,20 @@ handle_ident(struct asm_parser_state *state, const char *text, YYSTYPE *lval) } \ } while(0); +#define YY_NO_INPUT + +/* Yes, this is intentionally doing nothing. We have this line of code +here only to avoid the compiler complaining about an unput function +that is defined, but never called. */ +#define YY_USER_INIT while (0) { unput(0); } + #define YY_EXTRA_TYPE struct asm_parser_state * + +/* Flex defines a couple of functions with no declarations nor the +static keyword. Declare them here to avoid a compiler warning. */ +int yyget_column (yyscan_t yyscanner); +void yyset_column (int column_no , yyscan_t yyscanner); + %} num [0-9]+