diff options
author | Matt Turner <[email protected]> | 2015-07-29 10:47:51 -0700 |
---|---|---|
committer | Matt Turner <[email protected]> | 2015-07-31 10:33:03 -0700 |
commit | 616355160d3ee6edff3429b1abef82f0706dad3d (patch) | |
tree | b460355e6673787ca98d84c9ffcd48e7fa091220 | |
parent | b15aba940a3b6fc7c9bebc692968e7e9b72b9f29 (diff) |
glsl: Initialize parse-state in constructor of lower_subroutine.
Static analysis tools don't like partial object initializations.
Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]>
-rw-r--r-- | src/glsl/lower_subroutine.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/glsl/lower_subroutine.cpp b/src/glsl/lower_subroutine.cpp index e45ccfea6d9..b29912ad150 100644 --- a/src/glsl/lower_subroutine.cpp +++ b/src/glsl/lower_subroutine.cpp @@ -37,7 +37,8 @@ namespace { class lower_subroutine_visitor : public ir_hierarchical_visitor { public: - lower_subroutine_visitor() + lower_subroutine_visitor(struct _mesa_glsl_parse_state *state) + : state(state) { this->progress = false; } @@ -52,8 +53,7 @@ public: bool lower_subroutine(exec_list *instructions, struct _mesa_glsl_parse_state *state) { - lower_subroutine_visitor v; - v.state = state; + lower_subroutine_visitor v(state); visit_list_elements(&v, instructions); return v.progress; } |