build fix

This commit is contained in:
programsnail 2024-06-30 11:36:33 +03:00
parent 7fe9040449
commit e27cc09b4d
2 changed files with 3 additions and 3 deletions

View file

@ -270,7 +270,7 @@ bool TypeStorage::resolve(TypeProxy generic,
error_handling::ensure(generic.get()->is_generic(), "Type should be generic"); error_handling::ensure(generic.get()->is_generic(), "Type should be generic");
for (auto &type : storage_) { for (auto &type : storage_) {
if (type.is_generic() && if (type.is_generic() &&
type.get()->get_name() == generic.get()->get_name()) { type.get_name() == generic.get()->get_name()) {
type = replacement; type = replacement;
// type.mode = mode; // type.mode = mode;
} }

View file

@ -79,7 +79,7 @@ std::optional<const T *> find_statement(
std::optional<const nodes::TypeDefinition *> std::optional<const nodes::TypeDefinition *>
find_type_definition(const std::string &name, const nodes::Node &node, find_type_definition(const std::string &name, const nodes::Node &node,
SourcesManager &sources_manager, bool handle_errors) { SourcesManager &sources_manager, bool handle_errors) {
return find_statement_handle_errors<nodes::TypeDefinition>( return find_statement<nodes::TypeDefinition>(
name, node, sources_manager, "No type definition found in name tree", name, node, sources_manager, "No type definition found in name tree",
"Node in name tree is not type definition", handle_errors); "Node in name tree is not type definition", handle_errors);
} }
@ -87,7 +87,7 @@ find_type_definition(const std::string &name, const nodes::Node &node,
std::optional<const nodes::FunctionDefinition *> std::optional<const nodes::FunctionDefinition *>
find_name_definition(const std::string &name, const nodes::Node &node, find_name_definition(const std::string &name, const nodes::Node &node,
SourcesManager &sources_manager, bool handle_errors) { SourcesManager &sources_manager, bool handle_errors) {
return find_statement_handle_errors<nodes::FunctionDefinition>( return find_statement<nodes::FunctionDefinition>(
name, node, sources_manager, "No name definition found in name tree", name, node, sources_manager, "No name definition found in name tree",
"Node in name tree is not name definition", handle_errors); "Node in name tree is not name definition", handle_errors);
} }