Start of new ANTLR4 based parser.
Very simple tests pass.
This commit is contained in:
parent
03b4194193
commit
fbbe832a05
44 changed files with 860 additions and 8 deletions
27
pglablib/sqlast/StatementList.h
Normal file
27
pglablib/sqlast/StatementList.h
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
#pragma once
|
||||
|
||||
#include "Node.h"
|
||||
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
namespace sqlast {
|
||||
|
||||
class Statement;
|
||||
|
||||
class StatementList: public Node
|
||||
{
|
||||
public:
|
||||
StatementList();
|
||||
|
||||
void Add(std::unique_ptr<Statement> &&statement);
|
||||
Statement &Get(int index);
|
||||
int Count() const;
|
||||
|
||||
private:
|
||||
using Statements = std::vector<std::unique_ptr<Statement>>;
|
||||
|
||||
Statements statements;
|
||||
};
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue