Struct darling_core::util::Ignored
source · [−]pub struct Ignored;
Expand description
An efficient way of discarding data from a syntax element.
All syntax elements will be successfully read into
the Ignored
struct, with all properties discarded.
Trait Implementations
sourceimpl FromDeriveInput for Ignored
impl FromDeriveInput for Ignored
sourcefn from_derive_input(_: &DeriveInput) -> Result<Self>
fn from_derive_input(_: &DeriveInput) -> Result<Self>
Create an instance from syn::DeriveInput
, or return an error.
sourceimpl FromGenericParam for Ignored
impl FromGenericParam for Ignored
fn from_generic_param(_: &GenericParam) -> Result<Self>
sourceimpl FromGenerics for Ignored
impl FromGenerics for Ignored
fn from_generics(_: &Generics) -> Result<Self>
sourceimpl FromMeta for Ignored
impl FromMeta for Ignored
sourcefn from_meta(_: &Meta) -> Result<Self>
fn from_meta(_: &Meta) -> Result<Self>
Create an instance from a syn::Meta
by dispatching to the format-appropriate
trait function. This generally should not be overridden by implementers. Read more
fn from_nested_meta(item: &NestedMeta) -> Result<Self>
sourcefn from_word() -> Result<Self>
fn from_word() -> Result<Self>
Create an instance from the presence of the word in the attribute with no additional options specified. Read more
sourcefn from_list(items: &[NestedMeta]) -> Result<Self>
fn from_list(items: &[NestedMeta]) -> Result<Self>
Create an instance from a list of nested meta items.
sourcefn from_value(value: &Lit) -> Result<Self>
fn from_value(value: &Lit) -> Result<Self>
Create an instance from a literal value of either foo = "bar"
or foo("bar")
.
This dispatches to the appropriate method based on the type of literal encountered,
and generally should not be overridden by implementers. Read more
sourcefn from_char(value: char) -> Result<Self>
fn from_char(value: char) -> Result<Self>
Create an instance from a char literal in a value position.
sourcefn from_string(value: &str) -> Result<Self>
fn from_string(value: &str) -> Result<Self>
Create an instance from a string literal in a value position.
sourceimpl FromTypeParam for Ignored
impl FromTypeParam for Ignored
fn from_type_param(_: &TypeParam) -> Result<Self>
sourceimpl FromVariant for Ignored
impl FromVariant for Ignored
sourcefn from_variant(_: &Variant) -> Result<Self>
fn from_variant(_: &Variant) -> Result<Self>
Create an instance from syn::Variant
, or return an error.
sourceimpl UsesLifetimes for Ignored
impl UsesLifetimes for Ignored
sourcefn uses_lifetimes<'a>(
&self,
_opts: &Options,
_: &'a LifetimeSet
) -> LifetimeRefSet<'a>
fn uses_lifetimes<'a>(
&self,
_opts: &Options,
_: &'a LifetimeSet
) -> LifetimeRefSet<'a>
Returns the subset of the queried lifetimes that are used by the implementing syntax element. Read more
sourcefn uses_lifetimes_cloned(
&self,
options: &Options,
lifetimes: &LifetimeSet
) -> LifetimeSet
fn uses_lifetimes_cloned(
&self,
options: &Options,
lifetimes: &LifetimeSet
) -> LifetimeSet
Find all used lifetimes, then clone them and return that set.
sourceimpl UsesTypeParams for Ignored
impl UsesTypeParams for Ignored
sourcefn uses_type_params<'a>(
&self,
_opts: &Options,
_: &'a IdentSet
) -> IdentRefSet<'a>
fn uses_type_params<'a>(
&self,
_opts: &Options,
_: &'a IdentSet
) -> IdentRefSet<'a>
Returns the subset of the queried type parameters that are used by the implementing syntax element. Read more
sourcefn uses_type_params_cloned(
&self,
options: &Options,
type_set: &IdentSet
) -> IdentSet
fn uses_type_params_cloned(
&self,
options: &Options,
type_set: &IdentSet
) -> IdentSet
Find all type params using uses_type_params
, then clone the found values and return the set.
impl Copy for Ignored
impl Eq for Ignored
impl StructuralEq for Ignored
impl StructuralPartialEq for Ignored
Auto Trait Implementations
impl RefUnwindSafe for Ignored
impl Send for Ignored
impl Sync for Ignored
impl Unpin for Ignored
impl UnwindSafe for Ignored
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more