Merge pull request #116888 from Chaosus/shader_fix_struct
Allow using a struct name as a variable name in shaders
This commit is contained in:
commit
cc970e91e5
1 changed files with 1 additions and 1 deletions
|
|
@ -8023,7 +8023,7 @@ Error ShaderLanguage::_parse_block(BlockNode *p_block, const FunctionInfo &p_fun
|
|||
}
|
||||
}
|
||||
|
||||
bool is_struct = shader->structs.has(tk.text);
|
||||
bool is_struct = shader->structs.has(tk.text) && !(p_block && _find_identifier(p_block, false, p_function_info, tk.text));
|
||||
bool is_var_init = false;
|
||||
bool is_condition = false;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue