Rename Query::step_is_definite -> is_pattern_guaranteed_at_step
This commit is contained in:
parent
f69c4861c3
commit
142f4b6438
5 changed files with 9 additions and 7 deletions
|
|
@ -1,4 +1,4 @@
|
|||
/* automatically generated by rust-bindgen 0.58.1 */
|
||||
/* automatically generated by rust-bindgen 0.59.1 */
|
||||
|
||||
pub type __darwin_size_t = ::std::os::raw::c_ulong;
|
||||
pub type FILE = [u64; 19usize];
|
||||
|
|
@ -659,7 +659,7 @@ extern "C" {
|
|||
) -> *const TSQueryPredicateStep;
|
||||
}
|
||||
extern "C" {
|
||||
pub fn ts_query_step_is_definite(self_: *const TSQuery, byte_offset: u32) -> bool;
|
||||
pub fn ts_query_is_pattern_guaranteed_at_step(self_: *const TSQuery, byte_offset: u32) -> bool;
|
||||
}
|
||||
extern "C" {
|
||||
#[doc = " Get the name and length of one of the query's captures, or one of the"]
|
||||
|
|
|
|||
|
|
@ -1586,8 +1586,10 @@ impl Query {
|
|||
///
|
||||
/// A query step is 'definite' if its parent pattern will be guaranteed to match
|
||||
/// successfully once it reaches the step.
|
||||
pub fn step_is_definite(&self, byte_offset: usize) -> bool {
|
||||
unsafe { ffi::ts_query_step_is_definite(self.ptr.as_ptr(), byte_offset as u32) }
|
||||
pub fn is_pattern_guaranteed_at_step(&self, byte_offset: usize) -> bool {
|
||||
unsafe {
|
||||
ffi::ts_query_is_pattern_guaranteed_at_step(self.ptr.as_ptr(), byte_offset as u32)
|
||||
}
|
||||
}
|
||||
|
||||
fn parse_property(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue