GCC pragma causes warning on non-GNU compilers

This commit is contained in:
DennySun2100 2023-08-21 11:54:09 -07:00 committed by GitHub
parent 535434f208
commit f4a6134461
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,7 +1,9 @@
#ifndef TREE_SITTER_API_H_
#define TREE_SITTER_API_H_
#ifdef __GNUC__
#pragma GCC visibility push(default)
#endif
#ifdef __cplusplus
extern "C" {
@ -1165,6 +1167,8 @@ void ts_set_allocator(
}
#endif
#ifdef __GNUC__
#pragma GCC visibility pop
#endif
#endif // TREE_SITTER_API_H_