Struct rustc_query_system::query::config::QueryVtable
source · [−]pub struct QueryVtable<CTX: QueryContext, K, V> {
pub anon: bool,
pub dep_kind: CTX::DepKind,
pub eval_always: bool,
pub cache_on_disk: bool,
pub compute: fn(_: CTX::DepContext, _: K) -> V,
pub hash_result: Option<fn(_: &mut StableHashingContext<'_>, _: &V) -> Fingerprint>,
pub handle_cycle_error: fn(_: CTX, _: DiagnosticBuilder<'_, ErrorGuaranteed>) -> V,
pub try_load_from_disk: Option<fn(_: CTX, _: SerializedDepNodeIndex) -> Option<V>>,
}
Fields
anon: bool
dep_kind: CTX::DepKind
eval_always: bool
cache_on_disk: bool
compute: fn(_: CTX::DepContext, _: K) -> V
hash_result: Option<fn(_: &mut StableHashingContext<'_>, _: &V) -> Fingerprint>
handle_cycle_error: fn(_: CTX, _: DiagnosticBuilder<'_, ErrorGuaranteed>) -> V
try_load_from_disk: Option<fn(_: CTX, _: SerializedDepNodeIndex) -> Option<V>>
Implementations
sourceimpl<CTX: QueryContext, K, V> QueryVtable<CTX, K, V>
impl<CTX: QueryContext, K, V> QueryVtable<CTX, K, V>
pub(crate) fn to_dep_node(
&self,
tcx: CTX::DepContext,
key: &K
) -> DepNode<CTX::DepKind> where
K: DepNodeParams<CTX::DepContext>,
pub(crate) fn compute(&self, tcx: CTX::DepContext, key: K) -> V
pub(crate) fn try_load_from_disk(
&self,
tcx: CTX,
index: SerializedDepNodeIndex
) -> Option<V>
Auto Trait Implementations
impl<CTX, K, V> RefUnwindSafe for QueryVtable<CTX, K, V> where
<CTX as HasDepContext>::DepKind: RefUnwindSafe,
impl<CTX, K, V> Send for QueryVtable<CTX, K, V>
impl<CTX, K, V> Sync for QueryVtable<CTX, K, V> where
<CTX as HasDepContext>::DepKind: Sync,
impl<CTX, K, V> Unpin for QueryVtable<CTX, K, V> where
<CTX as HasDepContext>::DepKind: Unpin,
impl<CTX, K, V> UnwindSafe for QueryVtable<CTX, K, V> where
<CTX as HasDepContext>::DepKind: UnwindSafe,
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
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.