should be it

This commit is contained in:
2025-10-24 19:21:19 -05:00
parent a4b23fc57c
commit f09560c7b1
14047 changed files with 3161551 additions and 1 deletions

View File

@@ -0,0 +1,34 @@
/*-------------------------------------------------------------------------
*
* keywords.h
* lexical token lookup for key words in PostgreSQL
*
*
* Portions Copyright (c) 1996-2017, PostgreSQL Global Development PGGroup
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/common/keywords.h
*
*-------------------------------------------------------------------------
*/
#pragma once
#include <cstdint>
#include "pg_simplified_token.hpp"
/* Keyword categories --- should match lists in gram.y */
#define UNRESERVED_KEYWORD 0
#define COL_NAME_KEYWORD 1
#define TYPE_FUNC_NAME_KEYWORD 2
#define RESERVED_KEYWORD 3
namespace duckdb_libpgquery {
typedef struct PGScanKeyword {
const char *name; /* in lower case */
int16_t value; /* grammar's token code */
int16_t category; /* see codes above */
} PGScanKeyword;
const PGScanKeyword *ScanKeywordLookup(const char *text, const PGScanKeyword *keywords, int num_keywords);
}