Browse Source

restyleing

removed unnecessary check
cl-refactor
Liana Husikyan 10 years ago
parent
commit
581cd68fcf
  1. 3
      libsolidity/AST.h
  2. 3
      libsolidity/Parser.cpp

3
libsolidity/AST.h

@ -450,7 +450,8 @@ public:
Visibility _visibility,
bool _isStateVar = false,
bool _isIndexed = false,
bool _isConstant = false):
bool _isConstant = false
):
Declaration(_location, _name, _visibility),
m_typeName(_type),
m_value(_value),

3
libsolidity/Parser.cpp

@ -330,9 +330,6 @@ ASTPointer<VariableDeclaration> Parser::parseVariableDeclaration(
}
if (token == Token::Const)
{
solAssert(_options.isStateVariable, "");
if (m_scanner->peekNextToken() != Token::Identifier && !Token::isElementaryTypeName(m_scanner->peekNextToken()))
BOOST_THROW_EXCEPTION(createParserError("Invalid use of \"constant\" specifier"));
isDeclaredConst = true;
m_scanner->next();
}

Loading…
Cancel
Save