MCPcopy Create free account
hub / github.com/argotorg/solidity / type

Method type

libsolidity/experimental/ast/TypeSystem.cpp:316–325  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

314}
315
316experimental::Type TypeSystem::type(TypeConstructor _constructor, std::vector<Type> _arguments) const
317{
318 // TODO: proper error handling
319 auto const& info = m_typeConstructors.at(_constructor.m_index);
320 solAssert(
321 info.arguments() == _arguments.size(),
322 fmt::format("Type constructor '{}' accepts {} type arguments (got {}).", constructorInfo(_constructor).name, info.arguments(), _arguments.size())
323 );
324 return TypeConstant{_constructor, _arguments};
325}
326
327experimental::Type TypeEnvironment::fresh(Type _type)
328{

Callers 4

tupleTypeMethod · 0.45
sumTypeMethod · 0.45
functionTypeMethod · 0.45
typeFunctionTypeMethod · 0.45

Calls 3

atMethod · 0.80
argumentsMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected