Struct rustc_hir_typeck::closure::ExpectedSig
source · struct ExpectedSig<'tcx> {
cause_span: Option<Span>,
sig: PolyFnSig<'tcx>,
}
Expand description
What signature do we expect the closure to have from context?
Fields§
§cause_span: Option<Span>
Span that gave us this expectation, if we know that.
sig: PolyFnSig<'tcx>
Trait Implementations§
source§impl<'tcx> Clone for ExpectedSig<'tcx>
impl<'tcx> Clone for ExpectedSig<'tcx>
source§fn clone(&self) -> ExpectedSig<'tcx>
fn clone(&self) -> ExpectedSig<'tcx>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'tcx> Debug for ExpectedSig<'tcx>
impl<'tcx> Debug for ExpectedSig<'tcx>
source§impl<'tcx> TypeFoldable<TyCtxt<'tcx>> for ExpectedSig<'tcx>
impl<'tcx> TypeFoldable<TyCtxt<'tcx>> for ExpectedSig<'tcx>
source§fn try_fold_with<__F: FallibleTypeFolder<TyCtxt<'tcx>>>(
self,
__folder: &mut __F
) -> Result<Self, __F::Error>
fn try_fold_with<__F: FallibleTypeFolder<TyCtxt<'tcx>>>( self, __folder: &mut __F ) -> Result<Self, __F::Error>
source§fn fold_with<F>(self, folder: &mut F) -> Selfwhere
F: TypeFolder<I>,
fn fold_with<F>(self, folder: &mut F) -> Selfwhere F: TypeFolder<I>,
A convenient alternative to
try_fold_with
for use with infallible
folders. Do not override this method, to ensure coherence with
try_fold_with
.source§impl<'tcx> TypeVisitable<TyCtxt<'tcx>> for ExpectedSig<'tcx>
impl<'tcx> TypeVisitable<TyCtxt<'tcx>> for ExpectedSig<'tcx>
source§fn visit_with<__V: TypeVisitor<TyCtxt<'tcx>>>(
&self,
__visitor: &mut __V
) -> ControlFlow<__V::BreakTy>
fn visit_with<__V: TypeVisitor<TyCtxt<'tcx>>>( &self, __visitor: &mut __V ) -> ControlFlow<__V::BreakTy>
Auto Trait Implementations§
impl<'tcx> !RefUnwindSafe for ExpectedSig<'tcx>
impl<'tcx> !Send for ExpectedSig<'tcx>
impl<'tcx> !Sync for ExpectedSig<'tcx>
impl<'tcx> Unpin for ExpectedSig<'tcx>
impl<'tcx> !UnwindSafe for ExpectedSig<'tcx>
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
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: 40 bytes