pub struct PreprocessedTree {
pub path: Path,
pub value: PreprocessedValue,
pub used: Cell<UsageInfo<IsUsed>>,
}Expand description
An #[deftly()] attribute, or a sub-tree within one
Has interior mutability, for tracking whether the value is used. (So should ideally not be Clone, to help avoid aliasing bugs.)
Fields§
§path: Path§value: PreprocessedValue§used: Cell<UsageInfo<IsUsed>>Implementations§
Source§impl PreprocessedTree
impl PreprocessedTree
pub fn update_used(&self, ra: UsageInfo<IsUsed>)
Source§impl PreprocessedTree
impl PreprocessedTree
Sourcefn encode_useds(list: &PreprocessedValueList) -> Option<Group>
fn encode_useds(list: &PreprocessedValueList) -> Option<Group>
Returns (....)
Sourcefn encode_used(&self, out: &mut TokenOutputTrimmer<'_, '_>)
fn encode_used(&self, out: &mut TokenOutputTrimmer<'_, '_>)
Writes path?=(...) (or, rather, the parts of it that are needed)
Source§impl PreprocessedTree
impl PreprocessedTree
fn check_used<'c>(&'c self, checker: &mut UsedChecker<'c, '_>)
Trait Implementations§
Source§impl Debug for PreprocessedTree
impl Debug for PreprocessedTree
Source§impl Parse for PreprocessedTree
impl Parse for PreprocessedTree
fn parse(input: ParseStream<'_>) -> Result<Self>
Auto Trait Implementations§
impl !Freeze for PreprocessedTree
impl !RefUnwindSafe for PreprocessedTree
impl !Send for PreprocessedTree
impl !Sync for PreprocessedTree
impl Unpin for PreprocessedTree
impl UnwindSafe for PreprocessedTree
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more