[Bug 96729] Wrong shader compilation error message

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Sat Jul 9 03:21:12 UTC 2016


https://bugs.freedesktop.org/show_bug.cgi?id=96729

--- Comment #1 from Ilia Mirkin <imirkin at alum.mit.edu> ---
This is happening because there's a ast_add_assign node, which first figures
out the compatible type based on the add operation, and implicitly converts the
"other" side. So we end up with

(i2f v.y) += (128 * x)

And of course the i2f isn't an lvalue, hence the error. The issue is that
ast_to_hir.cpp::arithmetic_result_type has no concept that an assignment is
taking place, and happily applies the conversion. My initial thought was that
we should pass the fact that it's an assignment through, but that gets a little
nasty.

My second thought is that in an assign situation, the arithmetic_result_type
has to return the (original) op[0]'s type. If not, then we should throw an
error. And this applies to all the other instances of this.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/intel-3d-bugs/attachments/20160709/7948a022/attachment.html>


More information about the intel-3d-bugs mailing list