glsl/ast: update rhs in addition to the var's constant_value
authorIlia Mirkin <imirkin@alum.mit.edu>
Tue, 15 Aug 2017 17:47:08 +0000 (13:47 -0400)
committerIlia Mirkin <imirkin@alum.mit.edu>
Wed, 16 Aug 2017 02:14:05 +0000 (22:14 -0400)
commit978c4c597aa48e65bd6822a85e6b8f82ca9281f1
tree47d97dc7afdac57a359fa6bf7a3df9a77acd5777
parent98983503cbc8adb2d66f8b031e205fefcf5b6278
glsl/ast: update rhs in addition to the var's constant_value

We continue in the code to do some more things with the rhs, including
setting a constant initializer. If the type is wrong, this causes some
confusion down the line, leading to assertions. This makes sure that the
rhs processing continues to flow as-if the type was correct to start
with (even though the state has been marked as an error state).

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101766
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Cc: mesa-stable@lists.freedesktop.org
src/compiler/glsl/ast_to_hir.cpp