aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/parsing
diff options
context:
space:
mode:
authorDaniel Kirchner <daniel@ekpyron.org>2018-04-05 02:53:23 +0800
committerDaniel Kirchner <daniel@ekpyron.org>2018-04-05 17:52:22 +0800
commit96eff0ff6abc614cb44a01137dfd0df1ef750088 (patch)
treeb59ade23a7a3c87f4286400d7a8476acc7f5b892 /libsolidity/parsing
parentc63efebd4517d51f29082a8d0cff814a4922243d (diff)
downloaddexon-solidity-96eff0ff6abc614cb44a01137dfd0df1ef750088.tar.gz
dexon-solidity-96eff0ff6abc614cb44a01137dfd0df1ef750088.tar.zst
dexon-solidity-96eff0ff6abc614cb44a01137dfd0df1ef750088.zip
Error when using empty parenthesis for base class constructors that require arguments.
Diffstat (limited to 'libsolidity/parsing')
-rw-r--r--libsolidity/parsing/Parser.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/libsolidity/parsing/Parser.cpp b/libsolidity/parsing/Parser.cpp
index 3dbd4c8f..9a7731d8 100644
--- a/libsolidity/parsing/Parser.cpp
+++ b/libsolidity/parsing/Parser.cpp
@@ -286,17 +286,17 @@ ASTPointer<InheritanceSpecifier> Parser::parseInheritanceSpecifier()
RecursionGuard recursionGuard(*this);
ASTNodeFactory nodeFactory(*this);
ASTPointer<UserDefinedTypeName> name(parseUserDefinedTypeName());
- vector<ASTPointer<Expression>> arguments;
+ unique_ptr<vector<ASTPointer<Expression>>> arguments;
if (m_scanner->currentToken() == Token::LParen)
{
m_scanner->next();
- arguments = parseFunctionCallListArguments();
+ arguments.reset(new vector<ASTPointer<Expression>>(parseFunctionCallListArguments()));
nodeFactory.markEndPosition();
expectToken(Token::RParen);
}
else
nodeFactory.setEndPositionFromNode(name);
- return nodeFactory.createNode<InheritanceSpecifier>(name, arguments);
+ return nodeFactory.createNode<InheritanceSpecifier>(name, std::move(arguments));
}
Declaration::Visibility Parser::parseVisibilitySpecifier(Token::Value _token)