From: Brian Paul Date: Wed, 27 Apr 2011 15:23:16 +0000 (-0600) Subject: mesa: emit more info in program parser error message X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f3c92c2323b1a00e592a2bae739c420a52d4285b;p=mesa.git mesa: emit more info in program parser error message --- diff --git a/src/mesa/program/program_parse.y b/src/mesa/program/program_parse.y index 85c783dd637..dbf5abaa617 100644 --- a/src/mesa/program/program_parse.y +++ b/src/mesa/program/program_parse.y @@ -1258,7 +1258,11 @@ optArraySize: | INTEGER { if (($1 < 1) || ((unsigned) $1 > state->limits->MaxParameters)) { - yyerror(& @1, state, "invalid parameter array size"); + char msg[100]; + _mesa_snprintf(msg, sizeof(msg), + "invalid parameter array size (size=%d max=%u)", + $1, state->limits->MaxParameters); + yyerror(& @1, state, msg); YYERROR; } else { $$ = $1;