pub(crate) struct MaybeTransmutableQuery<L, C>where
C: QueryContext,{
src: L,
dst: L,
scope: <C as QueryContext>::Scope,
assume: Assume,
context: C,
}
Fields§
§src: L
§dst: L
§scope: <C as QueryContext>::Scope
§assume: Assume
§context: C
Implementations§
source§impl<'tcx> MaybeTransmutableQuery<Ty<'tcx>, TyCtxt<'tcx>>
impl<'tcx> MaybeTransmutableQuery<Ty<'tcx>, TyCtxt<'tcx>>
source§impl<L, C> MaybeTransmutableQuery<L, C>where
C: QueryContext,
impl<L, C> MaybeTransmutableQuery<L, C>where C: QueryContext,
pub(crate) fn new( src: L, dst: L, scope: <C as QueryContext>::Scope, assume: Assume, context: C ) -> Self
pub(crate) fn map_layouts<F, M>( self, f: F ) -> Result<MaybeTransmutableQuery<M, C>, Answer<<C as QueryContext>::Ref>>where F: FnOnce(L, L, <C as QueryContext>::Scope, &C) -> Result<(M, M), Answer<<C as QueryContext>::Ref>>,
source§impl<C> MaybeTransmutableQuery<Tree<<C as QueryContext>::Def, <C as QueryContext>::Ref>, C>where
C: QueryContext,
impl<C> MaybeTransmutableQuery<Tree<<C as QueryContext>::Def, <C as QueryContext>::Ref>, C>where C: QueryContext,
sourcepub(crate) fn answer(self) -> Answer<<C as QueryContext>::Ref>
pub(crate) fn answer(self) -> Answer<<C as QueryContext>::Ref>
Answers whether a Tree
is transmutable into another Tree
.
This method begins by de-def’ing src
and dst
, and prunes private paths from dst
,
then converts src
and dst
to Nfa
s, and computes an answer using those NFAs.
source§impl<C> MaybeTransmutableQuery<Nfa<<C as QueryContext>::Ref>, C>where
C: QueryContext,
impl<C> MaybeTransmutableQuery<Nfa<<C as QueryContext>::Ref>, C>where C: QueryContext,
sourcepub(crate) fn answer(self) -> Answer<<C as QueryContext>::Ref>
pub(crate) fn answer(self) -> Answer<<C as QueryContext>::Ref>
Answers whether a Nfa
is transmutable into another Nfa
.
This method converts src
and dst
to DFAs, then computes an answer using those DFAs.
source§impl<C> MaybeTransmutableQuery<Dfa<<C as QueryContext>::Ref>, C>where
C: QueryContext,
impl<C> MaybeTransmutableQuery<Dfa<<C as QueryContext>::Ref>, C>where C: QueryContext,
sourcepub(crate) fn answer(self) -> Answer<<C as QueryContext>::Ref>
pub(crate) fn answer(self) -> Answer<<C as QueryContext>::Ref>
Answers whether a Nfa
is transmutable into another Nfa
.
This method converts src
and dst
to DFAs, then computes an answer using those DFAs.
source§impl<'l, C> MaybeTransmutableQuery<&'l Dfa<<C as QueryContext>::Ref>, C>where
C: QueryContext,
impl<'l, C> MaybeTransmutableQuery<&'l Dfa<<C as QueryContext>::Ref>, C>where C: QueryContext,
pub(crate) fn answer(&mut self) -> Answer<<C as QueryContext>::Ref>
fn answer_memo( &self, cache: &mut Map<(State, State), Answer<<C as QueryContext>::Ref>>, src_state: State, dst_state: State ) -> Answer<<C as QueryContext>::Ref>
Auto Trait Implementations§
impl<L, C> RefUnwindSafe for MaybeTransmutableQuery<L, C>where C: RefUnwindSafe, L: RefUnwindSafe, <C as QueryContext>::Scope: RefUnwindSafe,
impl<L, C> Send for MaybeTransmutableQuery<L, C>where C: Send, L: Send, <C as QueryContext>::Scope: Send,
impl<L, C> Sync for MaybeTransmutableQuery<L, C>where C: Sync, L: Sync, <C as QueryContext>::Scope: Sync,
impl<L, C> Unpin for MaybeTransmutableQuery<L, C>where C: Unpin, L: Unpin, <C as QueryContext>::Scope: Unpin,
impl<L, C> UnwindSafe for MaybeTransmutableQuery<L, C>where C: UnwindSafe, L: UnwindSafe, <C as QueryContext>::Scope: UnwindSafe,
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: Unable to compute type layout, possibly due to this type having generic parameters. Layout can only be computed for concrete, fully-instantiated types.