mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #338 from guanqun/add_paren
support syntax "(x) = 3"
This commit is contained in:
@@ -792,7 +792,10 @@ bool TypeChecker::visit(TupleExpression const& _tuple)
|
||||
}
|
||||
else
|
||||
types.push_back(TypePointer());
|
||||
_tuple.annotation().type = make_shared<TupleType>(types);
|
||||
if (components.size() == 1)
|
||||
_tuple.annotation().type = type(*components[0]);
|
||||
else
|
||||
_tuple.annotation().type = make_shared<TupleType>(types);
|
||||
// If some of the components are not LValues, the error is reported above.
|
||||
_tuple.annotation().isLValue = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user