]>
Commit | Line | Data |
---|---|---|
49aad941 FG |
1 | pub mod bug; |
2 | pub mod call_kind; | |
3 | pub mod common; | |
4 | pub mod find_self_call; | |
5 | ||
6 | pub use call_kind::{call_kind, CallDesugaringKind, CallKind}; | |
7 | pub use find_self_call::find_self_call; | |
781aab86 FG |
8 | |
9 | #[derive(Default, Copy, Clone)] | |
10 | pub struct Providers { | |
11 | pub queries: rustc_middle::query::Providers, | |
12 | pub extern_queries: rustc_middle::query::ExternProviders, | |
13 | pub hooks: rustc_middle::hooks::Providers, | |
14 | } | |
15 | ||
16 | /// Backwards compatibility hack to keep the diff small. This | |
17 | /// gives direct access to the `queries` field's fields, which | |
18 | /// are what almost everything wants access to. | |
19 | impl std::ops::DerefMut for Providers { | |
20 | fn deref_mut(&mut self) -> &mut Self::Target { | |
21 | &mut self.queries | |
22 | } | |
23 | } | |
24 | ||
25 | impl std::ops::Deref for Providers { | |
26 | type Target = rustc_middle::query::Providers; | |
27 | ||
28 | fn deref(&self) -> &Self::Target { | |
29 | &self.queries | |
30 | } | |
31 | } |