mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Fix crash on assignment to non-lvalue.
This commit is contained in:
parent
b8fc58850d
commit
cb75e6218b
@ -1124,7 +1124,9 @@ bool TypeChecker::visit(Assignment const& _assignment)
|
||||
_assignment.annotation().type = make_shared<TupleType>();
|
||||
expectType(_assignment.rightHandSide(), *tupleType);
|
||||
|
||||
checkDoubleStorageAssignment(_assignment);
|
||||
// expectType does not cause fatal errors, so we have to check again here.
|
||||
if (dynamic_cast<TupleType const*>(type(_assignment.rightHandSide()).get()))
|
||||
checkDoubleStorageAssignment(_assignment);
|
||||
}
|
||||
else if (t->category() == Type::Category::Mapping)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user