Split expressions into separate files

This commit is contained in:
Rafał Grodziński
2025-06-23 17:01:52 +09:00
parent 4bab8077af
commit 7960c7c198
26 changed files with 368 additions and 372 deletions

View File

@@ -4,9 +4,11 @@
#include <vector>
#include "Lexer/Token.h"
#include "Expression.h"
#include "Parser/Statement/Statement.h"
class Expression;
class ExpressionInvalid;
class Statement;
class StatementInvalid;
using namespace std;
@@ -18,13 +20,11 @@ private:
shared_ptr<Statement> nextStatement();
shared_ptr<Statement> matchStatementFunctionDeclaration();
shared_ptr<Statement> matchStatementVarDeclaration();
shared_ptr<Statement> matchStatementVariable();
shared_ptr<Statement> matchStatementBlock(vector<TokenKind> terminalTokenKinds, bool shouldConsumeTerminal);
shared_ptr<Statement> matchStatementReturn();
shared_ptr<Statement> matchStatementExpression();
shared_ptr<Statement> matchStatementMetaExternFunction();
shared_ptr<StatementInvalid> matchStatementInvalid(string message = "");
shared_ptr<Expression> nextExpression();