mirror of
https://github.com/neovim/neovim.git
synced 2025-10-06 01:46:29 +00:00
api/vim: Add nvim_parse_expression function
This commit is contained in:
@@ -849,8 +849,7 @@ static inline void viml_pexpr_debug_print_token(
|
||||
viml_pexpr_debug_print_token(pstate, tkn)
|
||||
#endif
|
||||
|
||||
#ifndef NDEBUG
|
||||
static const uint8_t node_maxchildren[] = {
|
||||
const uint8_t node_maxchildren[] = {
|
||||
[kExprNodeMissing] = 0,
|
||||
[kExprNodeOpMissing] = 2,
|
||||
[kExprNodeTernary] = 2,
|
||||
@@ -890,7 +889,6 @@ static const uint8_t node_maxchildren[] = {
|
||||
[kExprNodeOption] = 0,
|
||||
[kExprNodeEnvironment] = 0,
|
||||
};
|
||||
#endif
|
||||
|
||||
/// Free memory occupied by AST
|
||||
///
|
||||
|
@@ -338,6 +338,9 @@ typedef struct {
|
||||
ExprASTNode *root;
|
||||
} ExprAST;
|
||||
|
||||
/// Array mapping ExprASTNodeType to maximum amount of children node may have
|
||||
extern const uint8_t node_maxchildren[];
|
||||
|
||||
#ifdef INCLUDE_GENERATED_DECLARATIONS
|
||||
# include "viml/parser/expressions.h.generated.h"
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user