diff --git a/src/compiler/glsl/glsl_to_nir.cpp b/src/compiler/glsl/glsl_to_nir.cpp index 50c02e34e77..8c96e914387 100644 --- a/src/compiler/glsl/glsl_to_nir.cpp +++ b/src/compiler/glsl/glsl_to_nir.cpp @@ -486,6 +486,9 @@ get_nir_how_declared(unsigned how_declared) if (how_declared == ir_var_hidden) return nir_var_hidden; + if (how_declared == ir_var_declared_implicitly) + return nir_var_declared_implicitly; + return nir_var_declared_normally; } diff --git a/src/compiler/nir/nir.h b/src/compiler/nir/nir.h index 3e5188611de..a96e9b78567 100644 --- a/src/compiler/nir/nir.h +++ b/src/compiler/nir/nir.h @@ -430,6 +430,12 @@ typedef enum { */ nir_var_declared_normally = 0, + /** + * Variable is an implicitly declared built-in that has not been explicitly + * re-declared by the shader. + */ + nir_var_declared_implicitly, + /** * Variable is implicitly generated by the compiler and should not be * visible via the API.