Browse Source

⬆️ tree-sitter-cli (new ABI version)

pull/8/head
Max Brunsfeld 8 years ago
parent
commit
b75677343e
3 changed files with 10 additions and 8 deletions
  1. +1
    -2
      package.json
  2. +1
    -1
      src/parser.c
  3. +8
    -5
      src/tree_sitter/parser.h

+ 1
- 2
package.json View File

@ -10,11 +10,10 @@
"author": "Max Brunsfeld",
"license": "MIT",
"dependencies": {
"bindings": "1.2.x",
"nan": "^2.10.0"
},
"devDependencies": {
"tree-sitter-cli": "^0.12.6"
"tree-sitter-cli": "^0.13.1"
},
"scripts": {
"build": "tree-sitter generate && node-gyp build",

+ 1
- 1
src/parser.c View File

@ -5,7 +5,7 @@
#pragma GCC diagnostic ignored "-Wmissing-field-initializers"
#endif
#define LANGUAGE_VERSION 8
#define LANGUAGE_VERSION 9
#define STATE_COUNT 1428
#define SYMBOL_COUNT 208
#define ALIAS_COUNT 18

+ 8
- 5
src/tree_sitter/parser.h View File

@ -25,13 +25,16 @@ typedef struct {
bool named : 1;
} TSSymbolMetadata;
typedef struct {
void (*advance)(void *, bool);
void (*mark_end)(void *);
uint32_t (*get_column)(void *);
typedef struct TSLexer TSLexer;
struct TSLexer {
int32_t lookahead;
TSSymbol result_symbol;
} TSLexer;
void (*advance)(TSLexer *, bool);
void (*mark_end)(TSLexer *);
uint32_t (*get_column)(TSLexer *);
bool (*is_at_included_range_start)(TSLexer *);
};
typedef enum {
TSParseActionTypeShift,

Loading…
Cancel
Save