diff options
author | vvvv <[email protected]> | 2025-02-18 14:49:48 +0300 |
---|---|---|
committer | vvvv <[email protected]> | 2025-02-18 16:08:18 +0300 |
commit | 1213d16b7fd20d4255d2ebb709a1745efbfeb91b (patch) | |
tree | a1cd11d96b5abf0a0ec287c76c4f3cfe9b32a86e /yql/essentials/sql/v1/proto_parser/proto_parser.h | |
parent | 408888e6801333da2d97af0b27a1c4da4448b9e0 (diff) |
Introduced lexer & parser interfaces
commit_hash:fee365c90a176dd33a967cee20994b21d530080c
Diffstat (limited to 'yql/essentials/sql/v1/proto_parser/proto_parser.h')
-rw-r--r-- | yql/essentials/sql/v1/proto_parser/proto_parser.h | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/yql/essentials/sql/v1/proto_parser/proto_parser.h b/yql/essentials/sql/v1/proto_parser/proto_parser.h index 14440953196..6e9ba07cac4 100644 --- a/yql/essentials/sql/v1/proto_parser/proto_parser.h +++ b/yql/essentials/sql/v1/proto_parser/proto_parser.h @@ -14,9 +14,24 @@ namespace NSQLTranslation { namespace NSQLTranslationV1 { - google::protobuf::Message* SqlAST(const TString& query, const TString& queryName, + struct TParsers { + NSQLTranslation::TParserFactoryPtr Antlr3; + NSQLTranslation::TParserFactoryPtr Antlr3Ansi; + NSQLTranslation::TParserFactoryPtr Antlr4; + NSQLTranslation::TParserFactoryPtr Antlr4Ansi; + }; + + //FIXME remove + TParsers MakeAllParsers(); + + //FIXME remove + google::protobuf::Message* SqlAST(const TString& query, const TString& queryName, NYql::TIssues& err, size_t maxErrors, bool ansiLexer, bool antlr4Parser, bool testAntlr4, google::protobuf::Arena* arena); google::protobuf::Message* SqlAST(const TString& query, const TString& queryName, NProtoAST::IErrorCollector& err, bool ansiLexer, bool antlr4Parser, bool testAntlr4, google::protobuf::Arena* arena); + google::protobuf::Message* SqlAST(const TParsers& parsers, const TString& query, const TString& queryName, + NYql::TIssues& err, size_t maxErrors, bool ansiLexer, bool antlr4Parser, google::protobuf::Arena* arena); + google::protobuf::Message* SqlAST(const TParsers& parsers, const TString& query, const TString& queryName, + NProtoAST::IErrorCollector& err, bool ansiLexer, bool antlr4Parser, google::protobuf::Arena* arena); } // namespace NSQLTranslationV1 |