glsl: add has_implicit_uint_to_int_conversion()-helper
[mesa.git] / src / compiler / glsl / ast_to_hir.cpp
index 6d4b2c6aa5dd01c5385105af72bfde3e714a5f26..7f30a7088551883b7be9aa1295ac50b00704aaa7 100644 (file)
@@ -250,8 +250,7 @@ get_implicit_conversion_operation(const glsl_type *to, const glsl_type *from,
       }
 
    case GLSL_TYPE_UINT:
-      if (!state->is_version(400, 0) && !state->ARB_gpu_shader5_enable
-          && !state->MESA_shader_integer_functions_enable)
+      if (!state->has_implicit_uint_to_int_conversion())
          return (ir_expression_operation)0;
       switch (from->base_type) {
          case GLSL_TYPE_INT: return ir_unop_i2u;