-
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathfix-emacs30-treesit.c.patch
More file actions
106 lines (98 loc) · 3.15 KB
/
fix-emacs30-treesit.c.patch
File metadata and controls
106 lines (98 loc) · 3.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
Binary files emacs/.git/index and fixed/.git/index differ
diff -crN emacs/src/treesit.c fixed/src/treesit.c
*** emacs/src/treesit.c Sat Mar 7 21:55:50 2026
--- fixed/src/treesit.c Sat Mar 7 21:58:51 2026
***************
*** 34,40 ****
# include "w32common.h"
/* In alphabetical order. */
! #undef ts_language_version
#undef ts_node_child
#undef ts_node_child_by_field_name
#undef ts_node_child_count
--- 34,40 ----
# include "w32common.h"
/* In alphabetical order. */
! #undef ts_language_abi_version
#undef ts_node_child
#undef ts_node_child_by_field_name
#undef ts_node_child_count
***************
*** 89,95 ****
#undef ts_tree_get_changed_ranges
#undef ts_tree_root_node
! DEF_DLL_FN (uint32_t, ts_language_version, (const TSLanguage *));
DEF_DLL_FN (TSNode, ts_node_child, (TSNode, uint32_t));
DEF_DLL_FN (TSNode, ts_node_child_by_field_name,
(TSNode, const char *, uint32_t));
--- 89,95 ----
#undef ts_tree_get_changed_ranges
#undef ts_tree_root_node
! DEF_DLL_FN (uint32_t, ts_language_abi_version, (const TSLanguage *));
DEF_DLL_FN (TSNode, ts_node_child, (TSNode, uint32_t));
DEF_DLL_FN (TSNode, ts_node_child_by_field_name,
(TSNode, const char *, uint32_t));
***************
*** 166,172 ****
if (!library)
return false;
! LOAD_DLL_FN (library, ts_language_version);
LOAD_DLL_FN (library, ts_node_child);
LOAD_DLL_FN (library, ts_node_child_by_field_name);
LOAD_DLL_FN (library, ts_node_child_count);
--- 166,172 ----
if (!library)
return false;
! LOAD_DLL_FN (library, ts_language_abi_version);
LOAD_DLL_FN (library, ts_node_child);
LOAD_DLL_FN (library, ts_node_child_by_field_name);
LOAD_DLL_FN (library, ts_node_child_count);
***************
*** 224,230 ****
return true;
}
! #define ts_language_version fn_ts_language_version
#define ts_node_child fn_ts_node_child
#define ts_node_child_by_field_name fn_ts_node_child_by_field_name
#define ts_node_child_count fn_ts_node_child_count
--- 224,230 ----
return true;
}
! #define ts_language_abi_version fn_ts_language_abi_version
#define ts_node_child fn_ts_node_child
#define ts_node_child_by_field_name fn_ts_node_child_by_field_name
#define ts_node_child_count fn_ts_node_child_count
***************
*** 746,752 ****
{
*signal_symbol = Qtreesit_load_language_error;
*signal_data = list2 (Qversion_mismatch,
! make_fixnum (ts_language_version (lang)));
return NULL;
}
return lang;
--- 746,752 ----
{
*signal_symbol = Qtreesit_load_language_error;
*signal_data = list2 (Qversion_mismatch,
! make_fixnum (ts_language_abi_version (lang)));
return NULL;
}
return lang;
***************
*** 817,823 ****
&signal_data);
if (ts_language == NULL)
return Qnil;
! uint32_t version = ts_language_version (ts_language);
return make_fixnum((ptrdiff_t) version);
}
}
--- 817,823 ----
&signal_data);
if (ts_language == NULL)
return Qnil;
! uint32_t version = ts_language_abi_version (ts_language);
return make_fixnum((ptrdiff_t) version);
}
}