diff options
Diffstat (limited to 'src/librustc_query_system')
| -rw-r--r-- | src/librustc_query_system/Cargo.toml | 1 | ||||
| -rw-r--r-- | src/librustc_query_system/dep_graph/dep_node.rs | 5 | ||||
| -rw-r--r-- | src/librustc_query_system/dep_graph/graph.rs | 2 | ||||
| -rw-r--r-- | src/librustc_query_system/dep_graph/prev.rs | 2 | ||||
| -rw-r--r-- | src/librustc_query_system/dep_graph/serialized.rs | 2 | ||||
| -rw-r--r-- | src/librustc_query_system/lib.rs | 2 |
6 files changed, 9 insertions, 5 deletions
diff --git a/src/librustc_query_system/Cargo.toml b/src/librustc_query_system/Cargo.toml index 64af9c5f1a1..c1ec452e001 100644 --- a/src/librustc_query_system/Cargo.toml +++ b/src/librustc_query_system/Cargo.toml @@ -15,6 +15,7 @@ log = { package = "tracing", version = "0.1" } rustc-rayon-core = "0.3.0" rustc_data_structures = { path = "../librustc_data_structures" } rustc_errors = { path = "../librustc_errors" } +rustc_macros = { path = "../librustc_macros" } rustc_index = { path = "../librustc_index" } rustc_serialize = { path = "../librustc_serialize" } rustc_span = { path = "../librustc_span" } diff --git a/src/librustc_query_system/dep_graph/dep_node.rs b/src/librustc_query_system/dep_graph/dep_node.rs index 002b0f9c165..e302784cc3e 100644 --- a/src/librustc_query_system/dep_graph/dep_node.rs +++ b/src/librustc_query_system/dep_graph/dep_node.rs @@ -50,7 +50,7 @@ use rustc_data_structures::stable_hasher::{HashStable, StableHasher}; use std::fmt; use std::hash::Hash; -#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, RustcEncodable, RustcDecodable)] +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Encodable, Decodable)] pub struct DepNode<K> { pub kind: K, pub hash: Fingerprint, @@ -152,7 +152,8 @@ impl<Ctxt: DepContext> DepNodeParams<Ctxt> for () { /// some independent path or string that persists between runs without /// the need to be mapped or unmapped. (This ensures we can serialize /// them even in the absence of a tcx.) -#[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Hash, RustcEncodable, RustcDecodable)] +#[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Hash)] +#[derive(Encodable, Decodable)] pub struct WorkProductId { hash: Fingerprint, } diff --git a/src/librustc_query_system/dep_graph/graph.rs b/src/librustc_query_system/dep_graph/graph.rs index 04a45090b72..d70306b4869 100644 --- a/src/librustc_query_system/dep_graph/graph.rs +++ b/src/librustc_query_system/dep_graph/graph.rs @@ -857,7 +857,7 @@ impl<K: DepKind> DepGraph<K> { /// may be added -- for example, new monomorphizations -- even if /// nothing in P changed!). We will compare that hash against the /// previous hash. If it matches up, we can reuse the object file. -#[derive(Clone, Debug, RustcEncodable, RustcDecodable)] +#[derive(Clone, Debug, Encodable, Decodable)] pub struct WorkProduct { pub cgu_name: String, /// Saved file associated with this CGU. diff --git a/src/librustc_query_system/dep_graph/prev.rs b/src/librustc_query_system/dep_graph/prev.rs index 5cba64cac4b..29357ce9449 100644 --- a/src/librustc_query_system/dep_graph/prev.rs +++ b/src/librustc_query_system/dep_graph/prev.rs @@ -3,7 +3,7 @@ use super::{DepKind, DepNode}; use rustc_data_structures::fingerprint::Fingerprint; use rustc_data_structures::fx::FxHashMap; -#[derive(Debug, RustcEncodable, RustcDecodable)] +#[derive(Debug, Encodable, Decodable)] pub struct PreviousDepGraph<K: DepKind> { data: SerializedDepGraph<K>, index: FxHashMap<DepNode<K>, SerializedDepNodeIndex>, diff --git a/src/librustc_query_system/dep_graph/serialized.rs b/src/librustc_query_system/dep_graph/serialized.rs index 4a89da23ea6..932c6d2a2f1 100644 --- a/src/librustc_query_system/dep_graph/serialized.rs +++ b/src/librustc_query_system/dep_graph/serialized.rs @@ -9,7 +9,7 @@ rustc_index::newtype_index! { } /// Data for use when recompiling the **current crate**. -#[derive(Debug, RustcEncodable, RustcDecodable)] +#[derive(Debug, Encodable, Decodable)] pub struct SerializedDepGraph<K: DepKind> { /// The set of all DepNodes in the graph pub nodes: IndexVec<SerializedDepNodeIndex, DepNode<K>>, diff --git a/src/librustc_query_system/lib.rs b/src/librustc_query_system/lib.rs index 4bbba7befe9..db104398f16 100644 --- a/src/librustc_query_system/lib.rs +++ b/src/librustc_query_system/lib.rs @@ -10,6 +10,8 @@ extern crate log; #[macro_use] extern crate rustc_data_structures; +#[macro_use] +extern crate rustc_macros; pub mod cache; pub mod dep_graph; |
