Skip to content

Commit 312e967

Browse files
committed
Update the minimum external LLVM to 13
1 parent abd46e1 commit 312e967

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

core/src/cmp.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1139,11 +1139,7 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
11391139
#[must_use]
11401140
#[stable(feature = "rust1", since = "1.0.0")]
11411141
fn le(&self, other: &Rhs) -> bool {
1142-
// Pattern `Some(Less | Eq)` optimizes worse than negating `None | Some(Greater)`.
1143-
// FIXME: The root cause was fixed upstream in LLVM with:
1144-
// https://github.com/llvm/llvm-project/commit/9bad7de9a3fb844f1ca2965f35d0c2a3d1e11775
1145-
// Revert this workaround once support for LLVM 12 gets dropped.
1146-
!matches!(self.partial_cmp(other), None | Some(Greater))
1142+
matches!(self.partial_cmp(other), Some(Less | Equal))
11471143
}
11481144

11491145
/// This method tests greater than (for `self` and `other`) and is used by the `>` operator.

0 commit comments

Comments
 (0)