pub struct FragmentRef {
pub file: usize,
pub unit: usize,
pub start_byte: usize,
pub end_byte: usize,
pub extent: u32,
pub run: Option<StatementRun>,
}Expand description
One occurrence of a hashed fragment (a statement window or a subtree) at a
source location. file indexes the slice given to generate; unit
indexes that file’s FileFeatures::units.
Fields§
§file: usizeIndex of the file in the input slice.
unit: usizeIndex of the enclosing unit in the file’s units.
start_byte: usizeAnchor: first byte the fragment covers.
end_byte: usizeAnchor: one past the last byte the fragment covers.
extent: u32Kind-specific size: window length or subtree node count.
run: Option<StatementRun>The statement run this fragment covers, for a statement window. None
for a subtree, which is a tree region rather than a run of siblings.
Trait Implementations§
Source§impl Clone for FragmentRef
impl Clone for FragmentRef
Source§fn clone(&self) -> FragmentRef
fn clone(&self) -> FragmentRef
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for FragmentRef
Source§impl Debug for FragmentRef
impl Debug for FragmentRef
impl Eq for FragmentRef
Source§impl Ord for FragmentRef
impl Ord for FragmentRef
Source§fn cmp(&self, other: &FragmentRef) -> Ordering
fn cmp(&self, other: &FragmentRef) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for FragmentRef
impl PartialEq for FragmentRef
Source§impl PartialOrd for FragmentRef
impl PartialOrd for FragmentRef
impl StructuralPartialEq for FragmentRef
Auto Trait Implementations§
impl Freeze for FragmentRef
impl RefUnwindSafe for FragmentRef
impl Send for FragmentRef
impl Sync for FragmentRef
impl Unpin for FragmentRef
impl UnsafeUnpin for FragmentRef
impl UnwindSafe for FragmentRef
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.