glsl: Fix type mismatch when incrementing or decrementing uint.
authorPaul Berry <stereotype441@gmail.com>
Tue, 1 Nov 2011 01:22:48 +0000 (18:22 -0700)
committerPaul Berry <stereotype441@gmail.com>
Wed, 2 Nov 2011 16:28:54 +0000 (09:28 -0700)
commit9abda92b270596fd3a5e2e8b74e3fc3255da70ce
tree6860a505226509221acd9fe6316486de2ae8f134
parenta0d8e5d12a059fcb5e606c262d30e41ad6248282
glsl: Fix type mismatch when incrementing or decrementing uint.

When converting an expression like "++x" to GLSL IR we were failing to
account for the possibility that x might be an unsigned integral type.
As a result the user would receive a bogus error message "Could not
implicitly convert operands to arithmetic operator".

Fixes piglit tests {vs,fs}-{increment,decrement}-uint.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/glsl/ast_to_hir.cpp