tree-sitter 0.20, --abi=14

This commit is contained in:
Shadowfacts 2022-05-28 10:40:53 -04:00
parent 29f53d8f4f
commit 2b49f95b16
5 changed files with 105 additions and 6 deletions

View File

@ -1,7 +1,7 @@
[package]
name = "tree-sitter-html"
description = "html grammar for the tree-sitter parsing library"
version = "0.19.0"
version = "0.20.0"
keywords = ["incremental", "parsing", "html"]
categories = ["parsing", "text-editors"]
repository = "https://github.com/tree-sitter/tree-sitter-html"
@ -19,7 +19,7 @@ include = [
path = "bindings/rust/lib.rs"
[dependencies]
tree-sitter = "0.19"
tree-sitter = "0.20"
[build-dependencies]
cc = "1.0"

View File

@ -35,7 +35,7 @@ pub const NODE_TYPES: &'static str = include_str!("../../src/node-types.json");
// Uncomment these to include any queries that this grammar contains
// pub const HIGHLIGHTS_QUERY: &'static str = include_str!("../../queries/highlights.scm");
pub const HIGHLIGHTS_QUERY: &'static str = include_str!("../../queries/highlights.scm");
// pub const INJECTIONS_QUERY: &'static str = include_str!("../../queries/injections.scm");
// pub const LOCALS_QUERY: &'static str = include_str!("../../queries/locals.scm");
// pub const TAGS_QUERY: &'static str = include_str!("../../queries/tags.scm");

View File

@ -1,6 +1,6 @@
{
"name": "tree-sitter-html",
"version": "0.19.0",
"version": "0.20.0",
"description": "HTML grammar for tree-sitter",
"main": "bindings/node",
"keywords": [
@ -20,7 +20,7 @@
"nan": "^2.14.0"
},
"devDependencies": {
"tree-sitter-cli": "^0.19.1"
"tree-sitter-cli": "^0.20.0"
},
"scripts": {
"test": "tree-sitter test && tree-sitter parse examples/*.html --quiet --time",

100
src/parser.c vendored
View File

@ -5,7 +5,7 @@
#pragma GCC diagnostic ignored "-Wmissing-field-initializers"
#endif
#define LANGUAGE_VERSION 13
#define LANGUAGE_VERSION 14
#define STATE_COUNT 94
#define LARGE_STATE_COUNT 2
#define SYMBOL_COUNT 40
@ -315,6 +315,103 @@ static const uint16_t ts_non_terminal_alias_map[] = {
0,
};
static const TSStateId ts_primary_state_ids[STATE_COUNT] = {
[0] = 0,
[1] = 1,
[2] = 2,
[3] = 2,
[4] = 4,
[5] = 4,
[6] = 6,
[7] = 6,
[8] = 8,
[9] = 9,
[10] = 10,
[11] = 11,
[12] = 12,
[13] = 13,
[14] = 11,
[15] = 15,
[16] = 16,
[17] = 12,
[18] = 18,
[19] = 19,
[20] = 10,
[21] = 13,
[22] = 22,
[23] = 23,
[24] = 24,
[25] = 25,
[26] = 26,
[27] = 27,
[28] = 28,
[29] = 15,
[30] = 27,
[31] = 16,
[32] = 9,
[33] = 33,
[34] = 25,
[35] = 23,
[36] = 22,
[37] = 24,
[38] = 19,
[39] = 18,
[40] = 40,
[41] = 41,
[42] = 42,
[43] = 43,
[44] = 40,
[45] = 45,
[46] = 46,
[47] = 28,
[48] = 48,
[49] = 43,
[50] = 50,
[51] = 51,
[52] = 51,
[53] = 53,
[54] = 54,
[55] = 55,
[56] = 54,
[57] = 55,
[58] = 53,
[59] = 59,
[60] = 60,
[61] = 61,
[62] = 62,
[63] = 63,
[64] = 64,
[65] = 65,
[66] = 62,
[67] = 67,
[68] = 63,
[69] = 48,
[70] = 50,
[71] = 64,
[72] = 65,
[73] = 73,
[74] = 67,
[75] = 75,
[76] = 76,
[77] = 77,
[78] = 78,
[79] = 79,
[80] = 80,
[81] = 81,
[82] = 82,
[83] = 82,
[84] = 76,
[85] = 85,
[86] = 78,
[87] = 87,
[88] = 87,
[89] = 81,
[90] = 79,
[91] = 80,
[92] = 85,
[93] = 75,
};
static bool ts_lex(TSLexer *lexer, TSStateId state) {
START_LEXER();
eof = lexer->eof(lexer);
@ -1920,6 +2017,7 @@ extern const TSLanguage *tree_sitter_html(void) {
tree_sitter_html_external_scanner_serialize,
tree_sitter_html_external_scanner_deserialize,
},
.primary_state_ids = ts_primary_state_ids,
};
return &language;
}

View File

@ -123,6 +123,7 @@ struct TSLanguage {
unsigned (*serialize)(void *, char *);
void (*deserialize)(void *, const char *, unsigned);
} external_scanner;
const TSStateId *primary_state_ids;
};
/*