From 516e965bfd6aabbbeeb82b540d595ef03ca891d9 Mon Sep 17 00:00:00 2001 From: pierwill Date: Tue, 22 Feb 2022 15:56:37 -0600 Subject: [PATCH] Remove unused ordering derivations and bounds for `SimplifiedTypeGen` --- compiler/rustc_middle/src/ty/fast_reject.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/compiler/rustc_middle/src/ty/fast_reject.rs b/compiler/rustc_middle/src/ty/fast_reject.rs index 983057bff95d6..3c1ac66e2d136 100644 --- a/compiler/rustc_middle/src/ty/fast_reject.rs +++ b/compiler/rustc_middle/src/ty/fast_reject.rs @@ -17,7 +17,7 @@ pub type SimplifiedType = SimplifiedTypeGen; /// because we sometimes need to use SimplifiedTypeGen values as stable sorting /// keys (in which case we use a DefPathHash as id-type) but in the general case /// the non-stable but fast to construct DefId-version is the better choice. -#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, TyEncodable, TyDecodable)] +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, TyEncodable, TyDecodable)] pub enum SimplifiedTypeGen where D: Copy + Debug + Eq, @@ -124,7 +124,7 @@ pub fn simplify_type( } } -impl SimplifiedTypeGen { +impl SimplifiedTypeGen { pub fn def(self) -> Option { match self { AdtSimplifiedType(d) @@ -140,7 +140,7 @@ impl SimplifiedTypeGen { pub fn map_def(self, map: F) -> SimplifiedTypeGen where F: Fn(D) -> U, - U: Copy + Debug + Ord + Eq, + U: Copy + Debug + Eq, { match self { BoolSimplifiedType => BoolSimplifiedType, @@ -171,7 +171,7 @@ impl SimplifiedTypeGen { impl<'a, D> HashStable> for SimplifiedTypeGen where - D: Copy + Debug + Ord + Eq + HashStable>, + D: Copy + Debug + Eq + HashStable>, { fn hash_stable(&self, hcx: &mut StableHashingContext<'a>, hasher: &mut StableHasher) { mem::discriminant(self).hash_stable(hcx, hasher);