|
3 | 3 | //! manage the caches, and so forth. |
4 | 4 |
|
5 | 5 | use super::queries; |
6 | | -use rustc_middle::dep_graph::{DepKind, DepNode, DepNodeExt, DepNodeIndex, SerializedDepNodeIndex}; |
| 6 | +use rustc_middle::dep_graph::{DepKind, DepNode, DepNodeIndex, SerializedDepNodeIndex}; |
7 | 7 | use rustc_middle::ty::query::on_disk_cache; |
8 | 8 | use rustc_middle::ty::tls::{self, ImplicitCtxt}; |
9 | 9 | use rustc_middle::ty::{self, TyCtxt}; |
@@ -60,39 +60,6 @@ impl QueryContext for QueryCtxt<'tcx> { |
60 | 60 | } |
61 | 61 |
|
62 | 62 | fn try_force_from_dep_node(&self, dep_node: &DepNode) -> bool { |
63 | | - // FIXME: This match is just a workaround for incremental bugs and should |
64 | | - // be removed. https://github.com/rust-lang/rust/issues/62649 is one such |
65 | | - // bug that must be fixed before removing this. |
66 | | - match dep_node.kind { |
67 | | - DepKind::hir_owner | DepKind::hir_owner_nodes => { |
68 | | - if let Some(def_id) = dep_node.extract_def_id(**self) { |
69 | | - let def_id = def_id.expect_local(); |
70 | | - let hir_id = self.tcx.hir().local_def_id_to_hir_id(def_id); |
71 | | - if def_id != hir_id.owner { |
72 | | - // This `DefPath` does not have a |
73 | | - // corresponding `DepNode` (e.g. a |
74 | | - // struct field), and the ` DefPath` |
75 | | - // collided with the `DefPath` of a |
76 | | - // proper item that existed in the |
77 | | - // previous compilation session. |
78 | | - // |
79 | | - // Since the given `DefPath` does not |
80 | | - // denote the item that previously |
81 | | - // existed, we just fail to mark green. |
82 | | - return false; |
83 | | - } |
84 | | - } else { |
85 | | - // If the node does not exist anymore, we |
86 | | - // just fail to mark green. |
87 | | - return false; |
88 | | - } |
89 | | - } |
90 | | - _ => { |
91 | | - // For other kinds of nodes it's OK to be |
92 | | - // forced. |
93 | | - } |
94 | | - } |
95 | | - |
96 | 63 | debug!("try_force_from_dep_node({:?}) --- trying to force", dep_node); |
97 | 64 |
|
98 | 65 | // We must avoid ever having to call `force_from_dep_node()` for a |
|
0 commit comments