pub struct CapturedInput { /* private fields */ }Expand description
One captured declared input: the top-level token trees, and how many span handles the producer issued.
Implementations§
Source§impl CapturedInput
impl CapturedInput
Sourcepub fn trees(&self) -> &[CapturedTokenTree]
pub fn trees(&self) -> &[CapturedTokenTree]
The top-level trees, in the order they were written.
Sourcepub const fn issued(&self) -> usize
pub const fn issued(&self) -> usize
How many span handles the producer issued; a handle at or past this index names no token.
Sourcepub fn canonical_bytes(&self) -> Vec<u8> ⓘ
pub fn canonical_bytes(&self) -> Vec<u8> ⓘ
The canonical bytes of this capture — what an identity over the declared input is derived from.
Deterministic and independent of span handles, so two captures of one declaration from different producers encode identically.
Trait Implementations§
Source§impl Clone for CapturedInput
impl Clone for CapturedInput
Source§fn clone(&self) -> CapturedInput
fn clone(&self) -> CapturedInput
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 moreSource§impl Debug for CapturedInput
impl Debug for CapturedInput
impl Eq for CapturedInput
Source§impl Hash for CapturedInput
impl Hash for CapturedInput
Source§impl PartialEq for CapturedInput
impl PartialEq for CapturedInput
impl StructuralPartialEq for CapturedInput
Auto Trait Implementations§
impl Freeze for CapturedInput
impl RefUnwindSafe for CapturedInput
impl Send for CapturedInput
impl Sync for CapturedInput
impl Unpin for CapturedInput
impl UnsafeUnpin for CapturedInput
impl UnwindSafe for CapturedInput
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