diff options
| author | Nicholas Nethercote <nnethercote@mozilla.com> | 2019-10-20 10:35:51 +1100 |
|---|---|---|
| committer | Nicholas Nethercote <nnethercote@mozilla.com> | 2019-10-21 13:45:21 +1100 |
| commit | 77c50dc508b8a0ea4277db6860c8d86288fd8538 (patch) | |
| tree | 64c64848afebedeb1623d8411fd4c47b0f35c000 | |
| parent | c23a7aa778b0dfeffbf83b099bdf971242c1e1ac (diff) | |
| download | rust-77c50dc508b8a0ea4277db6860c8d86288fd8538.tar.gz rust-77c50dc508b8a0ea4277db6860c8d86288fd8538.zip | |
Remove unnecessary trait bounds from `keys::Keys`.
| -rw-r--r-- | src/librustc/ty/query/keys.rs | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/librustc/ty/query/keys.rs b/src/librustc/ty/query/keys.rs index 30a3e53dddf..f61801cd232 100644 --- a/src/librustc/ty/query/keys.rs +++ b/src/librustc/ty/query/keys.rs @@ -8,14 +8,12 @@ use crate::ty::subst::SubstsRef; use crate::ty::fast_reject::SimplifiedType; use crate::mir; -use std::fmt::Debug; -use std::hash::Hash; use syntax_pos::{Span, DUMMY_SP}; use syntax_pos::symbol::InternedString; /// The `Key` trait controls what types can legally be used as the key /// for a query. -pub(super) trait Key: Clone + Hash + Eq + Debug { +pub(super) trait Key { /// Given an instance of this key, what crate is it referring to? /// This is used to find the provider. fn query_crate(&self) -> CrateNum; @@ -201,10 +199,7 @@ impl Key for InternedString { /// Canonical query goals correspond to abstract trait operations that /// are not tied to any crate in particular. -impl<'tcx, T> Key for Canonical<'tcx, T> -where - T: Debug + Hash + Clone + Eq, -{ +impl<'tcx, T> Key for Canonical<'tcx, T> { fn query_crate(&self) -> CrateNum { LOCAL_CRATE } |
