summaryrefslogtreecommitdiffstats
path: root/src/glsl/glsl_parser_extras.cpp
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2013-06-26 15:53:12 -0700
committerMatt Turner <[email protected]>2013-07-11 20:58:59 -0700
commit8d45caaebaa017e910ae985e005fadc6b626de7d (patch)
tree387d04eec10a9d4e9ad5a0b6ed2d61af3e07b06f /src/glsl/glsl_parser_extras.cpp
parent5df807b06f20d53063af9cfc5b4fc867f5fb810a (diff)
glsl: Add an is_declaration field to ast_struct_specifier.
Will be used in a later commit to differentiate between a structure type declaration and a variable declaration of a struct type. I.e., the difference between struct S { float x; }; (is_declaration = true) and S s; (is_declaration = false) Also note that is_declaration = true for struct S { float x; } s; Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/glsl/glsl_parser_extras.cpp')
-rw-r--r--src/glsl/glsl_parser_extras.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/glsl/glsl_parser_extras.cpp b/src/glsl/glsl_parser_extras.cpp
index 664f8d15917..aa5a435fa95 100644
--- a/src/glsl/glsl_parser_extras.cpp
+++ b/src/glsl/glsl_parser_extras.cpp
@@ -1236,6 +1236,7 @@ ast_struct_specifier::ast_struct_specifier(const char *identifier,
}
name = identifier;
this->declarations.push_degenerate_list_at_head(&declarator_list->link);
+ is_declaration = true;
}
extern "C" {