feat(c): rename DecodeFunction to TSDecodeFunction

Keep a typedef for backwards compatibility until ABI 16.
This commit is contained in:
ObserverOfTime 2025-08-23 10:18:15 +03:00 committed by Amaan Qureshi
parent dbe88f8bbb
commit b75196bb81
4 changed files with 11 additions and 8 deletions

View file

@ -35,7 +35,7 @@ pub struct TSQueryCursor {
pub struct TSLookaheadIterator {
_unused: [u8; 0],
}
pub type DecodeFunction = ::core::option::Option<
pub type TSDecodeFunction = ::core::option::Option<
unsafe extern "C" fn(string: *const u8, length: u32, code_point: *mut i32) -> u32,
>;
pub const TSInputEncodingUTF8: TSInputEncoding = 0;
@ -75,7 +75,7 @@ pub struct TSInput {
) -> *const ::core::ffi::c_char,
>,
pub encoding: TSInputEncoding,
pub decode: DecodeFunction,
pub decode: TSDecodeFunction,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]