glsl/glcpp: Minor tweak to wording of error message
authorCarl Worth <cworth@cworth.org>
Sat, 21 Jun 2014 02:11:27 +0000 (19:11 -0700)
committerCarl Worth <cworth@cworth.org>
Tue, 29 Jul 2014 22:11:49 +0000 (15:11 -0700)
It makes more sense to print the directive name with the preceding '#'.

Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
src/glsl/glcpp/glcpp-parse.y
src/glsl/glcpp/tests/077-else-without-if.c.expected
src/glsl/glcpp/tests/078-elif-without-if.c.expected

index a93c1e359f493e4858e17ad2f17b71cef9a919b7..840003b226ee2ef8be4ae67c369d7c535867d89c 100644 (file)
@@ -2119,7 +2119,7 @@ _glcpp_parser_skip_stack_change_if (glcpp_parser_t *parser, YYLTYPE *loc,
                                    const char *type, int condition)
 {
        if (parser->skip_stack == NULL) {
-               glcpp_error (loc, parser, "%s without #if\n", type);
+               glcpp_error (loc, parser, "#%s without #if\n", type);
                return;
        }
 
index cc1c379cad3e0219ea8812d073dbc3f95f854b25..64e6d1ac93e97455755b9b7e48d7f7f74cd26ff4 100644 (file)
@@ -1,3 +1,3 @@
-0:1(2): preprocessor error: else without #if
+0:1(2): preprocessor error: #else without #if
 
 
index ee3450133a24737adc30ebd3de59d1f8aeb2434e..f3530ed2c072aef13b8960c9984d9aad4b03eed6 100644 (file)
@@ -1,3 +1,3 @@
-0:1(2): preprocessor error: elif without #if
+0:1(2): preprocessor error: #elif without #if