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>

source§

fn cmpl_new_scope( &self, inner_scope_graph: &InnerScopeGraph<'_, LABEL, DATA>, scope: Scope )

source§

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

source§

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

source§

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>

source§

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>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<LABEL> Default for FutureCompleteness<LABEL>

source§

fn default() -> Self

Returns the “default value” for a type. Read more

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> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.