diff options
| author | Camille GILLOT <gillot.camille@gmail.com> | 2021-01-05 18:37:42 +0100 |
|---|---|---|
| committer | Camille GILLOT <gillot.camille@gmail.com> | 2021-02-19 17:51:55 +0100 |
| commit | ea3d465c95ce027aabfe7423c3d9f2161bdc2eb1 (patch) | |
| tree | fc382855af836cfe80b2fe608e054a016cd08a6d /compiler/rustc_query_system/src/query | |
| parent | 4dbf83a2091bea4027f0e6eae43c991f06ff46b9 (diff) | |
| download | rust-ea3d465c95ce027aabfe7423c3d9f2161bdc2eb1.tar.gz rust-ea3d465c95ce027aabfe7423c3d9f2161bdc2eb1.zip | |
Move try_load_from_on_disk_cache to the QueryContext.
Diffstat (limited to 'compiler/rustc_query_system/src/query')
| -rw-r--r-- | compiler/rustc_query_system/src/query/mod.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/compiler/rustc_query_system/src/query/mod.rs b/compiler/rustc_query_system/src/query/mod.rs index 2d678035d4d..8d5c9d7bea7 100644 --- a/compiler/rustc_query_system/src/query/mod.rs +++ b/compiler/rustc_query_system/src/query/mod.rs @@ -14,7 +14,7 @@ pub use self::caches::{ mod config; pub use self::config::{QueryAccessors, QueryConfig, QueryDescription}; -use crate::dep_graph::HasDepContext; +use crate::dep_graph::{DepNode, HasDepContext}; use crate::query::job::QueryMap; use rustc_data_structures::stable_hasher::HashStable; @@ -37,6 +37,9 @@ pub trait QueryContext: HasDepContext { fn try_collect_active_jobs(&self) -> Option<QueryMap<Self::DepKind, Self::Query>>; + /// Load data from the on-disk cache. + fn try_load_from_on_disk_cache(&self, dep_node: &DepNode<Self::DepKind>); + /// Executes a job by changing the `ImplicitCtxt` to point to the /// new query job while it executes. It returns the diagnostics /// captured during execution and the actual result. |
