aboutsummaryrefslogtreecommitdiffstats
path: root/Parser.h
diff options
context:
space:
mode:
authorChristian <c@ethdev.com>2014-10-09 02:53:50 +0800
committerChristian <c@ethdev.com>2014-10-09 02:53:50 +0800
commit0a1ebe4f516a5c1e8ebc12798a94529bdda9b6df (patch)
treedcc068f33caaa625872b1c1e612f6c362b13145f /Parser.h
parent56e9cc8db71f8af949123e13e6a97cc056cf766d (diff)
downloaddexon-solidity-0a1ebe4f516a5c1e8ebc12798a94529bdda9b6df.tar.gz
dexon-solidity-0a1ebe4f516a5c1e8ebc12798a94529bdda9b6df.tar.zst
dexon-solidity-0a1ebe4f516a5c1e8ebc12798a94529bdda9b6df.zip
Parse everything up to function bodies and report parser errors with location.
Diffstat (limited to 'Parser.h')
-rw-r--r--Parser.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/Parser.h b/Parser.h
index 4a48dace..96f1d688 100644
--- a/Parser.h
+++ b/Parser.h
@@ -32,7 +32,7 @@ class Scanner;
class Parser
{
public:
- ptr<ASTNode> parse(Scanner& _scanner);
+ ptr<ASTNode> parse(std::shared_ptr<Scanner> const& _scanner);
private:
class ASTNodeFactory;
@@ -48,6 +48,10 @@ private:
ptr<FunctionDefinition> parseFunctionDefinition(bool _isPublic);
ptr<StructDefinition> parseStructDefinition();
ptr<VariableDeclaration> parseVariableDeclaration();
+ ptr<TypeName> parseTypeName();
+ ptr<Mapping> parseMapping();
+ ptr<ParameterList> parseParameterList();
+ ptr<Block> parseBlock();
/// @}
/// Helper functions
@@ -58,7 +62,7 @@ private:
void throwExpectationError(const std::string& _description);
/// @}
- Scanner* m_scanner;
+ std::shared_ptr<Scanner> m_scanner;
};
} }