Struct scopegraphs::completeness::FutureCompleteness
source · pub struct FutureCompleteness<LABEL> { /* private fields */ }Expand description
A completeness strategy that makes queries return a Future
in case one of the scopes that the query runs over was not yet closed.
The future resolves once all such scopes are closed.
Using FutureCompleteness, you can somewhat delegate the task of scheduling
typechecking to one of rust’s executors, be it tokio
or futures::block_on.
Extends, and contains an instance of, ExplicitClose.
Trait Implementations§
source§impl<LABEL: Hash + Eq + Label + Copy, DATA> Completeness<LABEL, DATA> for FutureCompleteness<LABEL>
impl<LABEL: Hash + Eq + Label + Copy, DATA> Completeness<LABEL, DATA> for FutureCompleteness<LABEL>
fn cmpl_new_scope( &self, inner_scope_graph: &InnerScopeGraph<'_, LABEL, DATA>, scope: Scope )
source§fn cmpl_new_complete_scope(
&self,
_: &InnerScopeGraph<'_, LABEL, DATA>,
_: Scope
)
fn cmpl_new_complete_scope( &self, _: &InnerScopeGraph<'_, LABEL, DATA>, _: Scope )
Should initialize a scope without possibility to extend it with edges
type NewEdgeResult = <ExplicitClose<LABEL> as Completeness<LABEL, DATA>>::NewEdgeResult
fn cmpl_new_edge( &self, inner_scope_graph: &InnerScopeGraph<'_, LABEL, DATA>, src: Scope, lbl: LABEL, dst: Scope ) -> Self::NewEdgeResult
type GetEdgesResult<'rslv> = FutureWrapper<'rslv, Vec<Scope>> where Self: 'rslv, LABEL: 'rslv, DATA: 'rslv
fn cmpl_get_edges<'rslv>(
&'rslv self,
inner_scope_graph: &'rslv InnerScopeGraph<'_, LABEL, DATA>,
src: Scope,
lbl: LABEL
) -> Self::GetEdgesResult<'rslv>where
LABEL: 'rslv,
DATA: 'rslv,
source§impl<LABEL: Hash + Eq + Label + Copy, DATA> CriticalEdgeBasedCompleteness<LABEL, DATA> for FutureCompleteness<LABEL>
impl<LABEL: Hash + Eq + Label + Copy, DATA> CriticalEdgeBasedCompleteness<LABEL, DATA> for FutureCompleteness<LABEL>
source§fn init_scope_with(&self, open_edges: HashSet<LABEL>)
fn init_scope_with(&self, open_edges: HashSet<LABEL>)
Initializes a new scope with a certain set of edges that are still considered “open”.
source§impl<LABEL: Debug> Debug for FutureCompleteness<LABEL>
impl<LABEL: Debug> Debug for FutureCompleteness<LABEL>
Auto Trait Implementations§
impl<LABEL> !Freeze for FutureCompleteness<LABEL>
impl<LABEL> !RefUnwindSafe for FutureCompleteness<LABEL>
impl<LABEL> Send for FutureCompleteness<LABEL>where
LABEL: Send,
impl<LABEL> !Sync for FutureCompleteness<LABEL>
impl<LABEL> Unpin for FutureCompleteness<LABEL>where
LABEL: Unpin,
impl<LABEL> UnwindSafe for FutureCompleteness<LABEL>where
LABEL: 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