summaryrefslogtreecommitdiffstats
path: root/src/mesa/gl.pc.in
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2015-11-12 16:02:22 -0800
committerMatt Turner <[email protected]>2015-11-13 11:27:50 -0800
commit88f349c4e100acd5dd3e7137496444907a175c39 (patch)
tree6c9154ed8c74470bf1f9671f2a7c4a5920cb5de8 /src/mesa/gl.pc.in
parent3694d58e6c4a39bd84e8aef0d8e67c3ae9447f33 (diff)
i965/fs: Replace nested ternary with if ladder.
Since the types of the expression were bool ? src_reg : (bool ? brw_reg : brw_reg) the result of the second (nested) ternary would be implicitly converted to a src_reg by the src_reg(struct brw_reg) constructor. I.e., bool ? src_reg : src_reg(bool ? brw_reg : brw_reg) In the next patch, I make backend_reg (the parent of src_reg) inherit from brw_reg, which changes this expression to return brw_reg, which throws away any fields that exist in the classes derived from brw_reg. I.e., src_reg(bool ? brw_reg(src_reg) : bool ? brw_reg : brw_reg) Generally this code was gross, and wasn't actually shorter or easier to read than an if ladder. Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Chris Forbes <[email protected]>
Diffstat (limited to 'src/mesa/gl.pc.in')
0 files changed, 0 insertions, 0 deletions