Struct chalk_solve::rust_ir::TraitFlags
source · [−]pub struct TraitFlags {
pub auto: bool,
pub marker: bool,
pub upstream: bool,
pub fundamental: bool,
pub non_enumerable: bool,
pub coinductive: bool,
}Fields
auto: boolAn “auto trait” is one that is “automatically implemented” for every struct, so long as no explicit impl is given.
Examples are Send and Sync.
marker: boolupstream: boolIndicate that a trait is defined upstream (in a dependency), used during coherence checking.
fundamental: boolA fundamental trait is a trait where adding an impl for an existing type
is considered a breaking change. Examples of fundamental traits are the
closure traits like Fn and FnMut.
As of this writing (2020-03-27), fundamental traits are declared by the
unstable #[fundamental] attribute in rustc, and hence cannot appear
outside of the standard library.
non_enumerable: boolIndicates that chalk cannot list all of the implementations of the given trait, likely because it is a publicly exported trait in a library.
Currently (2020-03-27) rustc and rust-analyzer mark all traits as non_enumerable, and in the future it may become the only option.
coinductive: boolTrait Implementations
sourceimpl Clone for TraitFlags
impl Clone for TraitFlags
sourcefn clone(&self) -> TraitFlags
fn clone(&self) -> TraitFlags
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for TraitFlags
impl Debug for TraitFlags
sourceimpl Hash for TraitFlags
impl Hash for TraitFlags
sourceimpl PartialEq<TraitFlags> for TraitFlags
impl PartialEq<TraitFlags> for TraitFlags
sourcefn eq(&self, other: &TraitFlags) -> bool
fn eq(&self, other: &TraitFlags) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &TraitFlags) -> bool
fn ne(&self, other: &TraitFlags) -> bool
This method tests for !=.
sourceimpl<I: Interner> Visit<I> for TraitFlags
impl<I: Interner> Visit<I> for TraitFlags
sourcefn visit_with<B>(
&self,
_visitor: &mut dyn Visitor<I, BreakTy = B>,
_outer_binder: DebruijnIndex
) -> ControlFlow<B>
fn visit_with<B>(
&self,
_visitor: &mut dyn Visitor<I, BreakTy = B>,
_outer_binder: DebruijnIndex
) -> ControlFlow<B>
Apply the given visitor visitor to self; binders is the
number of binders that are in scope when beginning the
visitor. Typically binders starts as 0, but is adjusted when
we encounter Binders<T> in the IR or other similar
constructs. Read more
impl Eq for TraitFlags
impl StructuralEq for TraitFlags
impl StructuralPartialEq for TraitFlags
Auto Trait Implementations
impl RefUnwindSafe for TraitFlags
impl Send for TraitFlags
impl Sync for TraitFlags
impl Unpin for TraitFlags
impl UnwindSafe for TraitFlags
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> Cast for T
impl<T> Cast for T
sourcefn cast<U>(self, interner: <U as HasInterner>::Interner) -> U where
Self: CastTo<U>,
U: HasInterner,
fn cast<U>(self, interner: <U as HasInterner>::Interner) -> U where
Self: CastTo<U>,
U: HasInterner,
Cast a value to type U using CastTo.
sourceimpl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to key and return true if they are equal.
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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
sourceimpl<T, I> VisitExt<I> for T where
I: Interner,
T: Visit<I>,
impl<T, I> VisitExt<I> for T where
I: Interner,
T: Visit<I>,
sourcefn has_free_vars(&self, interner: I) -> bool
fn has_free_vars(&self, interner: I) -> bool
Check whether there are free (non-bound) variables.
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more