Fix global uniforms parsed as instance uniform

This commit is contained in:
Lily Garcia 2022-11-17 17:18:20 -05:00
parent 966785751f
commit 0683bc3783

View File

@ -8190,6 +8190,7 @@ Error ShaderLanguage::_parse_shader(const HashMap<StringName, FunctionInfo> &p_f
};
[[fallthrough]];
case TK_INSTANCE: {
if (tk.type == TK_INSTANCE) {
#ifdef DEBUG_ENABLED
keyword_completion_context = CF_UNIFORM_KEYWORD;
if (_lookup_next(next)) {
@ -8210,6 +8211,7 @@ Error ShaderLanguage::_parse_shader(const HashMap<StringName, FunctionInfo> &p_f
}
uniform_scope = ShaderNode::Uniform::SCOPE_INSTANCE;
}
}
};
[[fallthrough]];
case TK_UNIFORM: