summaryrefslogtreecommitdiffstats
path: root/src/glsl/glsl_lexer.ll
diff options
context:
space:
mode:
authorPaul Berry <[email protected]>2013-07-25 19:56:43 -0700
committerPaul Berry <[email protected]>2013-07-27 09:41:30 -0700
commit4d7899fe81b6ffc521c6f9688e25bcde4012e556 (patch)
treec230c0fce51c7b67a19223ca1f7601596cd76459 /src/glsl/glsl_lexer.ll
parent8c3d3622d9ce2fd2a8f46084ab8153d708fa5b09 (diff)
glsl: Be consistent about '\n', '.', and capitalization in errors/warnings.
The majority of calls to _mesa_glsl_error(), _mesa_glsl_warning(), and _mesa_glsl_parse_state::check_version() use a message that begins with a lower case letter and ends without a period. This patch makes all messages follow that convention. Also, error/warning messages shouldn't end in '\n', since _mesa_glsl_msg() automatically adds '\n' at the end of the message. Reviewed-by: Matt Turner <[email protected]>
Diffstat (limited to 'src/glsl/glsl_lexer.ll')
-rw-r--r--src/glsl/glsl_lexer.ll10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/glsl/glsl_lexer.ll b/src/glsl/glsl_lexer.ll
index 145119c2c72..b95b254da01 100644
--- a/src/glsl/glsl_lexer.ll
+++ b/src/glsl/glsl_lexer.ll
@@ -77,7 +77,7 @@ static int classify_identifier(struct _mesa_glsl_parse_state *, const char *);
} else if (yyextra->is_version(reserved_glsl, \
reserved_glsl_es)) { \
_mesa_glsl_error(yylloc, yyextra, \
- "Illegal use of reserved word `%s'", yytext); \
+ "illegal use of reserved word `%s'", yytext); \
return ERROR_TOK; \
} else { \
yylval->identifier = strdup(yytext); \
@@ -93,7 +93,7 @@ static int classify_identifier(struct _mesa_glsl_parse_state *, const char *);
do { \
if (yyextra->is_version(0, 300)) { \
_mesa_glsl_error(yylloc, yyextra, \
- "Illegal use of reserved word `%s'", yytext); \
+ "illegal use of reserved word `%s'", yytext); \
return ERROR_TOK; \
} else { \
return token; \
@@ -124,10 +124,10 @@ literal_integer(char *text, int len, struct _mesa_glsl_parse_state *state,
/* Note that signed 0xffffffff is valid, not out of range! */
if (state->is_version(130, 300)) {
_mesa_glsl_error(lloc, state,
- "Literal value `%s' out of range", text);
+ "literal value `%s' out of range", text);
} else {
_mesa_glsl_warning(lloc, state,
- "Literal value `%s' out of range", text);
+ "literal value `%s' out of range", text);
}
} else if (base == 10 && !is_uint && (unsigned)value > (unsigned)INT_MAX + 1) {
/* Tries to catch unintentionally providing a negative value.
@@ -135,7 +135,7 @@ literal_integer(char *text, int len, struct _mesa_glsl_parse_state *state,
* want to warn for INT_MAX.
*/
_mesa_glsl_warning(lloc, state,
- "Signed literal value `%s' is interpreted as %d",
+ "signed literal value `%s' is interpreted as %d",
text, lval->n);
}
return is_uint ? UINTCONSTANT : INTCONSTANT;