Skip to content

Commit 8de8c64

Browse files
committed
Remove unnecessary types from binding.rs
1 parent 9f535f9 commit 8de8c64

File tree

2 files changed

+9
-14
lines changed

2 files changed

+9
-14
lines changed

lib/binding_rust/bindings.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
/* automatically generated by rust-bindgen 0.59.1 */
22

3-
pub type __darwin_size_t = ::std::os::raw::c_ulong;
4-
pub type FILE = [u64; 19usize];
53
pub type TSSymbol = u16;
64
pub type TSFieldId = u16;
75
#[repr(C)]
@@ -359,10 +357,6 @@ extern "C" {
359357
length: *mut u32,
360358
) -> *mut TSRange;
361359
}
362-
extern "C" {
363-
#[doc = " Write a DOT graph describing the syntax tree to the given file."]
364-
pub fn ts_tree_print_dot_graph(arg1: *const TSTree, arg2: *mut FILE);
365-
}
366360
extern "C" {
367361
#[doc = " Get the node's type as a null-terminated string."]
368362
pub fn ts_node_type(arg1: TSNode) -> *const ::std::os::raw::c_char;

script/generate-bindings

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,15 @@
33
output_path=lib/binding_rust/bindings.rs
44
header_path='lib/include/tree_sitter/api.h'
55

6-
bindgen \
7-
--no-layout-tests \
8-
--whitelist-type '^TS.*' \
9-
--whitelist-function '^ts_.*' \
10-
--opaque-type FILE \
11-
--size_t-is-usize \
12-
--translate-enum-integer-types \
13-
--distrust-clang-mangling \
6+
bindgen \
7+
--no-layout-tests \
8+
--whitelist-type '^TS.*' \
9+
--whitelist-function '^ts_.*' \
10+
--opaque-type FILE \
11+
--blocklist-type FILE \
12+
--blocklist-type '^__.*' \
13+
--blocklist-function ts_tree_print_dot_graph \
14+
--size_t-is-usize \
1415
$header_path > $output_path
1516

1617
echo "" >> $output_path

0 commit comments

Comments
 (0)