File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -802,6 +802,9 @@ pub trait Ord: Eq + PartialOrd<Self> {
802802 Self : Sized ,
803803 Self : ~const Destruct ,
804804 {
805+ // HACK(fee1-dead): go back to using `self.max_by(other, Ord::cmp)`
806+ // when trait methods are allowed to be used when a const closure is
807+ // expected.
805808 match self . cmp ( & other) {
806809 Ordering :: Less | Ordering :: Equal => other,
807810 Ordering :: Greater => self ,
@@ -826,6 +829,9 @@ pub trait Ord: Eq + PartialOrd<Self> {
826829 Self : Sized ,
827830 Self : ~const Destruct ,
828831 {
832+ // HACK(fee1-dead): go back to using `self.min_by(other, Ord::cmp)`
833+ // when trait methods are allowed to be used when a const closure is
834+ // expected.
829835 match self . cmp ( & other) {
830836 Ordering :: Less | Ordering :: Equal => self ,
831837 Ordering :: Greater => other,
You can’t perform that action at this time.
0 commit comments