Skip to content

Commit 450c674

Browse files
committed
For now, don't implement ts_tree_print_dot_graph on windows
1 parent 0b817a6 commit 450c674

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

lib/src/tree.c

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
#include <unistd.h>
21
#include "tree_sitter/api.h"
32
#include "./array.h"
43
#include "./get_changed_ranges.h"
@@ -124,8 +123,21 @@ TSRange *ts_tree_get_changed_ranges(const TSTree *self, const TSTree *other, uin
124123
return result;
125124
}
126125

126+
#ifdef _WIN32
127+
128+
void ts_tree_print_dot_graph(const TSTree *self, int fd) {
129+
(void)self;
130+
(void)fd;
131+
}
132+
133+
#else
134+
135+
#include <unistd.h>
136+
127137
void ts_tree_print_dot_graph(const TSTree *self, int fd) {
128138
FILE *file = fdopen(dup(fd), "a");
129139
ts_subtree_print_dot_graph(self->root, self->language, file);
130140
fclose(file);
131141
}
142+
143+
#endif

0 commit comments

Comments
 (0)