diff options
author | Kenneth Graunke <[email protected]> | 2012-03-29 23:17:31 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2012-04-09 14:30:34 -0700 |
commit | b2c0df2b60a77b043d461f265c85d8b5b066a008 (patch) | |
tree | 6158f2c308c626139bbfd6444bf52cbb7c57a8f3 /src/glsl/glsl_parser_extras.cpp | |
parent | 68b99be409eb2d4f20198cfdb2c8fea75d754e0b (diff) |
glsl: Use (const char *) in AST nodes rather than plain (char *).
Nothing actually relied on them being mutable, and there was at least
one cast which discarded const qualifiers. The next patch would have
introduced many more.
Casting away const qualifiers should be avoided if at all possible.
Signed-off-by: Kenneth Graunke <[email protected]>
Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/glsl/glsl_parser_extras.cpp')
-rw-r--r-- | src/glsl/glsl_parser_extras.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/glsl/glsl_parser_extras.cpp b/src/glsl/glsl_parser_extras.cpp index 21c3c6ec2bc..6547ad2d3b7 100644 --- a/src/glsl/glsl_parser_extras.cpp +++ b/src/glsl/glsl_parser_extras.cpp @@ -713,7 +713,7 @@ ast_declaration::print(void) const } -ast_declaration::ast_declaration(char *identifier, int is_array, +ast_declaration::ast_declaration(const char *identifier, int is_array, ast_expression *array_size, ast_expression *initializer) { @@ -979,7 +979,7 @@ ast_struct_specifier::print(void) const } -ast_struct_specifier::ast_struct_specifier(char *identifier, +ast_struct_specifier::ast_struct_specifier(const char *identifier, ast_node *declarator_list) { if (identifier == NULL) { |