Skip to content

Commit 8a42e3d

Browse files
authored
Rollup merge of #94267 - pierwill:fast-reject-bound, r=michaelwoerister
Remove unused ordering derivations and bounds for `SimplifiedTypeGen` This is another small PR clearing the way for work on #90317.
2 parents 77a8e60 + 516e965 commit 8a42e3d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

compiler/rustc_middle/src/ty/fast_reject.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ pub type SimplifiedType = SimplifiedTypeGen<DefId>;
1717
/// because we sometimes need to use SimplifiedTypeGen values as stable sorting
1818
/// keys (in which case we use a DefPathHash as id-type) but in the general case
1919
/// the non-stable but fast to construct DefId-version is the better choice.
20-
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, TyEncodable, TyDecodable)]
20+
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, TyEncodable, TyDecodable)]
2121
pub enum SimplifiedTypeGen<D>
2222
where
2323
D: Copy + Debug + Eq,
@@ -124,7 +124,7 @@ pub fn simplify_type(
124124
}
125125
}
126126

127-
impl<D: Copy + Debug + Ord + Eq> SimplifiedTypeGen<D> {
127+
impl<D: Copy + Debug + Eq> SimplifiedTypeGen<D> {
128128
pub fn def(self) -> Option<D> {
129129
match self {
130130
AdtSimplifiedType(d)
@@ -140,7 +140,7 @@ impl<D: Copy + Debug + Ord + Eq> SimplifiedTypeGen<D> {
140140
pub fn map_def<U, F>(self, map: F) -> SimplifiedTypeGen<U>
141141
where
142142
F: Fn(D) -> U,
143-
U: Copy + Debug + Ord + Eq,
143+
U: Copy + Debug + Eq,
144144
{
145145
match self {
146146
BoolSimplifiedType => BoolSimplifiedType,
@@ -171,7 +171,7 @@ impl<D: Copy + Debug + Ord + Eq> SimplifiedTypeGen<D> {
171171

172172
impl<'a, D> HashStable<StableHashingContext<'a>> for SimplifiedTypeGen<D>
173173
where
174-
D: Copy + Debug + Ord + Eq + HashStable<StableHashingContext<'a>>,
174+
D: Copy + Debug + Eq + HashStable<StableHashingContext<'a>>,
175175
{
176176
fn hash_stable(&self, hcx: &mut StableHashingContext<'a>, hasher: &mut StableHasher) {
177177
mem::discriminant(self).hash_stable(hcx, hasher);

0 commit comments

Comments
 (0)