Otherwise, the upcoming error messages said the location was 0:0(0).

NOTE: This is a candidate for the 8.0 branch.
---
 src/glsl/glsl_parser.yy |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/glsl/glsl_parser.yy b/src/glsl/glsl_parser.yy
index e774b46..8368d06 100644
--- a/src/glsl/glsl_parser.yy
+++ b/src/glsl/glsl_parser.yy
@@ -1691,10 +1691,12 @@ case_label:
        CASE expression ':'
        {
           $$ = new(state) ast_case_label($2);
+          $$->set_location(yylloc);
        }
        | DEFAULT ':'
        {
           $$ = new(state) ast_case_label(NULL);
+          $$->set_location(yylloc);
        }
        ;
 
-- 
1.7.7.3

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to