diff --git a/libsolidity/Compiler.h b/libsolidity/Compiler.h index 76f16f3ab..4b1e1b4d6 100644 --- a/libsolidity/Compiler.h +++ b/libsolidity/Compiler.h @@ -94,8 +94,8 @@ private: std::vector m_continueTags; ///< tag to jump to for a "continue" statement eth::AssemblyItem m_returnTag; ///< tag to jump to for a "return" statement unsigned m_modifierDepth = 0; - FunctionDefinition const* m_currentFunction; - unsigned m_stackCleanupForReturn; ///< this number of stack elements need to be removed before jump to m_returnTag + FunctionDefinition const* m_currentFunction = nullptr; + unsigned m_stackCleanupForReturn = 0; ///< this number of stack elements need to be removed before jump to m_returnTag // arguments for base constructors, filled in derived-to-base order std::map> const*> m_baseArguments; }; diff --git a/libsolidity/Parser.h b/libsolidity/Parser.h index 87eb2f8ff..cc0b2ca17 100644 --- a/libsolidity/Parser.h +++ b/libsolidity/Parser.h @@ -34,6 +34,8 @@ class Scanner; class Parser { public: + Parser() {} + ASTPointer parse(std::shared_ptr const& _scanner); std::shared_ptr const& getSourceName() const; diff --git a/solc/CommandLineInterface.cpp b/solc/CommandLineInterface.cpp index 08acb5ebd..867e832d7 100644 --- a/solc/CommandLineInterface.cpp +++ b/solc/CommandLineInterface.cpp @@ -345,18 +345,11 @@ bool CommandLineInterface::processInput() void CommandLineInterface::handleAst(string const& _argStr) { string title; - string suffix; if (_argStr == g_argAstStr) - { title = "Syntax trees:"; - suffix = ".ast"; - } else if (_argStr == g_argAstJson) - { title = "JSON AST:"; - suffix = ".json"; - } else BOOST_THROW_EXCEPTION(InternalCompilerError() << errinfo_comment("Illegal argStr for AST"));