Don't rename remapped variables like 'gl_LastFragDepthARM'

This commit is contained in:
Yuwen Wu 2022-08-18 19:38:25 +08:00
parent 61c603f3ba
commit 33e19e86bf

View File

@ -342,6 +342,8 @@ void ParsedIR::set_name(ID id, const string &name)
{
auto &m = meta[id];
m.decoration.alias = name;
if (ids[id].get_type() == TypeVariable && get<SPIRVariable>(id).remapped_variable)
return;
if (!is_valid_identifier(name) || is_reserved_identifier(name, false, false))
meta_needing_name_fixup.insert(id);
}