[Fix] 修复TypeInfo Hash不一致问题,以及InterfaceType toString格式化

This commit is contained in:
2025-12-30 17:55:22 +08:00
parent ba0364fb51
commit b76d1e6edf
2 changed files with 2 additions and 2 deletions

View File

@@ -49,7 +49,7 @@ namespace Fig
public:
std::size_t operator()(const TypeInfo &ti) const
{
return ti.id;
return std::hash<size_t>{}(ti.id);
}
};

View File

@@ -461,7 +461,7 @@ namespace Fig
if (is<InterfaceType>())
{
return FString(std::format(
"<InterfaceType '{}' at {:p}",
"<InterfaceType '{}' at {:p}>",
as<InterfaceType>().type.toString().toBasicString(),
static_cast<const void *>(&as<InterfaceType>())));
}