mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
[Sol->Yul] Adding util function to copy literal to storage.
Co-authored-by: Daniel Kirchner <daniel@ekpyron.org> Co-authored-by: chriseth <chris@ethereum.org>
This commit is contained in:
co-authored by
Daniel Kirchner
chriseth
parent
9d156b52c4
commit
f0c5cdca9f
@@ -2613,23 +2613,6 @@ Type const* TupleType::mobileType() const
|
||||
return TypeProvider::tuple(move(mobiles));
|
||||
}
|
||||
|
||||
Type const* TupleType::closestTemporaryType(Type const* _targetType) const
|
||||
{
|
||||
solAssert(!!_targetType, "");
|
||||
TypePointers const& targetComponents = dynamic_cast<TupleType const&>(*_targetType).components();
|
||||
solAssert(components().size() == targetComponents.size(), "");
|
||||
TypePointers tempComponents(targetComponents.size());
|
||||
for (size_t i = 0; i < targetComponents.size(); ++i)
|
||||
{
|
||||
if (components()[i] && targetComponents[i])
|
||||
{
|
||||
tempComponents[i] = components()[i]->closestTemporaryType(targetComponents[i]);
|
||||
solAssert(tempComponents[i], "");
|
||||
}
|
||||
}
|
||||
return TypeProvider::tuple(move(tempComponents));
|
||||
}
|
||||
|
||||
FunctionType::FunctionType(FunctionDefinition const& _function, Kind _kind):
|
||||
m_kind(_kind),
|
||||
m_stateMutability(_function.stateMutability()),
|
||||
|
||||
Reference in New Issue
Block a user