From bc64b8980803a5ba1cc91c63dc2ed1517db800c6 Mon Sep 17 00:00:00 2001 From: Carl Worth Date: Wed, 11 Aug 2010 13:09:14 -0700 Subject: glcpp: Initialize line and column numbers to 1, not 0. Error messages make more sense this way since the convention is for the first line of a file to be numbered from 1, rather than 0. --- src/glsl/glcpp/glcpp-lex.l | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/glsl/glcpp/glcpp-lex.l b/src/glsl/glcpp/glcpp-lex.l index 1a0052d689..fa62891354 100644 --- a/src/glsl/glcpp/glcpp-lex.l +++ b/src/glsl/glcpp/glcpp-lex.l @@ -43,7 +43,7 @@ void glcpp_set_column (int column_no , yyscan_t yyscanner); yylloc->first_line = yylineno; \ yycolumn += yyleng; \ } while(0); -#define YY_USER_INIT yylineno = 0; yycolumn = 0; +#define YY_USER_INIT yylineno = 1; yycolumn = 1; %} %option bison-bridge bison-locations reentrant noyywrap -- cgit v1.2.3