[Sol->Yul] Implementing member access to arrays in calldata structs.

This commit is contained in:
Djordje Mijovic
2020-11-26 11:46:31 +01:00
parent 5f732cb3ca
commit bae32ac402
6 changed files with 90 additions and 2 deletions
@@ -1810,6 +1810,11 @@ void IRGeneratorForStatements::endVisit(MemberAccess const& _memberAccess)
", " <<
offset <<
")\n";
else if (
dynamic_cast<ArrayType const*>(_memberAccess.annotation().type) ||
dynamic_cast<StructType const*>(_memberAccess.annotation().type)
)
define(_memberAccess) << offset << "\n";
else
define(_memberAccess) <<
m_utils.readFromCalldata(*_memberAccess.annotation().type) <<