Remove unnecessary conflict (#66)

pull/844/head
Amaan Qureshi 2023-08-27 18:40:57 +07:00 committed by GitHub
parent 8302c98ed7
commit 07da684bad
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 7577 additions and 6185 deletions

@ -12,11 +12,6 @@ module.exports = grammar({
], ],
conflicts: ($) => [ conflicts: ($) => [
[$._maybe_record_expression, $._maybe_tuple_expression], [$._maybe_record_expression, $._maybe_tuple_expression],
[
$._maybe_record_expression,
$._maybe_tuple_expression,
$.remote_type_identifier,
],
[ [
$._maybe_record_expression, $._maybe_record_expression,
$._maybe_tuple_expression, $._maybe_tuple_expression,

5
src/grammar.json generated

@ -6245,11 +6245,6 @@
"_maybe_record_expression", "_maybe_record_expression",
"_maybe_tuple_expression" "_maybe_tuple_expression"
], ],
[
"_maybe_record_expression",
"_maybe_tuple_expression",
"remote_type_identifier"
],
[ [
"_maybe_record_expression", "_maybe_record_expression",
"_maybe_tuple_expression", "_maybe_tuple_expression",

13736
src/parser.c generated

File diff suppressed because it is too large Load Diff

@ -13,9 +13,8 @@ extern "C" {
#define ts_builtin_sym_end 0 #define ts_builtin_sym_end 0
#define TREE_SITTER_SERIALIZATION_BUFFER_SIZE 1024 #define TREE_SITTER_SERIALIZATION_BUFFER_SIZE 1024
typedef uint16_t TSStateId;
#ifndef TREE_SITTER_API_H_ #ifndef TREE_SITTER_API_H_
typedef uint16_t TSStateId;
typedef uint16_t TSSymbol; typedef uint16_t TSSymbol;
typedef uint16_t TSFieldId; typedef uint16_t TSFieldId;
typedef struct TSLanguage TSLanguage; typedef struct TSLanguage TSLanguage;
@ -130,9 +129,16 @@ struct TSLanguage {
* Lexer Macros * Lexer Macros
*/ */
#ifdef _MSC_VER
#define UNUSED __pragma(warning(suppress : 4101))
#else
#define UNUSED __attribute__((unused))
#endif
#define START_LEXER() \ #define START_LEXER() \
bool result = false; \ bool result = false; \
bool skip = false; \ bool skip = false; \
UNUSED \
bool eof = false; \ bool eof = false; \
int32_t lookahead; \ int32_t lookahead; \
goto start; \ goto start; \
@ -166,7 +172,7 @@ struct TSLanguage {
* Parse Table Macros * Parse Table Macros
*/ */
#define SMALL_STATE(id) id - LARGE_STATE_COUNT #define SMALL_STATE(id) ((id) - LARGE_STATE_COUNT)
#define STATE(id) id #define STATE(id) id
@ -176,7 +182,7 @@ struct TSLanguage {
{{ \ {{ \
.shift = { \ .shift = { \
.type = TSParseActionTypeShift, \ .type = TSParseActionTypeShift, \
.state = state_value \ .state = (state_value) \
} \ } \
}} }}
@ -184,7 +190,7 @@ struct TSLanguage {
{{ \ {{ \
.shift = { \ .shift = { \
.type = TSParseActionTypeShift, \ .type = TSParseActionTypeShift, \
.state = state_value, \ .state = (state_value), \
.repetition = true \ .repetition = true \
} \ } \
}} }}