Fix wrong construction of ElementaryTypeNameToken

And add an assert to prevent it in the future
This commit is contained in:
Mathias Baumann
2019-12-09 13:24:33 +00:00
committed by Mathias Baumann
parent e061f1e743
commit be615d4f2b
2 changed files with 4 additions and 1 deletions
+1 -1
View File
@@ -1678,7 +1678,7 @@ ASTPointer<Expression> Parser::parseLeftHandSideExpression(
expectToken(Token::Payable);
nodeFactory.markEndPosition();
auto expressionType = nodeFactory.createNode<ElementaryTypeName>(
ElementaryTypeNameToken(Token::Address, 160, 0),
ElementaryTypeNameToken(Token::Address, 0, 0),
std::make_optional(StateMutability::Payable)
);
expression = nodeFactory.createNode<ElementaryTypeNameExpression>(expressionType);