mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
fixup! Extract type class member registration into a separate experimental analysis pass
This commit is contained in:
parent
ea8daf1613
commit
4028125234
@ -557,6 +557,9 @@ bool TypeInference::visit(TypeClassInstantiation const& _typeClassInstantiation)
|
||||
[&](ASTPointer<IdentifierPath> _typeClassName) -> std::optional<TypeClass> {
|
||||
if (auto const* typeClassDefinition = dynamic_cast<TypeClassDefinition const*>(_typeClassName->annotation().referencedDeclaration))
|
||||
{
|
||||
// visiting the type class will re-visit this instantiation
|
||||
typeClassDefinition->accept(*this);
|
||||
|
||||
// TODO: more error handling? Should be covered by the visit above.
|
||||
solAssert(m_analysis.annotation<TypeClassRegistration>(*typeClassDefinition).typeClass.has_value());
|
||||
return m_analysis.annotation<TypeClassRegistration>(*typeClassDefinition).typeClass.value();
|
||||
|
Loading…
Reference in New Issue
Block a user