pub struct Trait {
pub is_auto: bool,
pub is_unsafe: bool,
pub is_dyn_compatible: bool,
pub items: Vec<Id>,
pub generics: Generics,
pub bounds: Vec<GenericBound>,
pub implementations: Vec<Id>,
}
Expand description
A trait
declaration.
Fields§
§is_auto: bool
Whether the trait is marked auto
and is thus implemented automatically
for all applicable types.
is_unsafe: bool
Whether the trait is marked as unsafe
.
is_dyn_compatible: bool
Whether the trait is dyn compatible1.
Formerly known as “object safe”. ↩
items: Vec<Id>
Associated Item
s that can/must be implemented by the impl
blocks.
generics: Generics
Information about the type parameters and where
clauses of the trait.
bounds: Vec<GenericBound>
Constraints that must be met by the implementor of the trait.
implementations: Vec<Id>
The implementations of the trait.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Trait
impl<'de> Deserialize<'de> for Trait
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Trait
impl StructuralPartialEq for Trait
Auto Trait Implementations§
impl Freeze for Trait
impl RefUnwindSafe for Trait
impl Send for Trait
impl Sync for Trait
impl Unpin for Trait
impl UnwindSafe for Trait
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 128 bytes