mesa: Dump shader source before validating the shader.
[mesa.git] / src / mesa / program / program_lexer.l
index 5730c6d761b907bbba44f68dcc7ea8dbff3b3d2b..0a50dab97fd4fd48e5d342febf1b16f98bf20bcd 100644 (file)
@@ -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]+