ARB prog parser: More robust error message for bad OPTION string

This commit is contained in:
Ian Romanick
2009-07-27 16:33:16 -07:00
parent 1edd13bf23
commit 41d5696628
2 changed files with 244 additions and 236 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -284,7 +284,11 @@ option: OPTION IDENTIFIER ';'
if (!valid) {
yyerror(& @2, state, "invalid option string");
const char *const err_str = (state->mode == ARB_vertex)
? "invalid ARB vertex program option"
: "invalid ARB fragment program option";
yyerror(& @2, state, err_str);
YYERROR;
}
}