@@ -848,6 +848,7 @@ pub trait Ord: Eq + PartialOrd<Self> {
848
848
#[ stable( feature = "ord_max_min" , since = "1.21.0" ) ]
849
849
#[ inline]
850
850
#[ must_use]
851
+ #[ cfg_attr( not( bootstrap) , rustc_diagnostic_item = "cmp_ord_max" ) ]
851
852
fn max ( self , other : Self ) -> Self
852
853
where
853
854
Self : Sized ,
@@ -868,6 +869,7 @@ pub trait Ord: Eq + PartialOrd<Self> {
868
869
#[ stable( feature = "ord_max_min" , since = "1.21.0" ) ]
869
870
#[ inline]
870
871
#[ must_use]
872
+ #[ cfg_attr( not( bootstrap) , rustc_diagnostic_item = "cmp_ord_min" ) ]
871
873
fn min ( self , other : Self ) -> Self
872
874
where
873
875
Self : Sized ,
@@ -1154,6 +1156,7 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
1154
1156
/// ```
1155
1157
#[ must_use]
1156
1158
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
1159
+ #[ cfg_attr( not( bootstrap) , rustc_diagnostic_item = "cmp_partialord_cmp" ) ]
1157
1160
fn partial_cmp ( & self , other : & Rhs ) -> Option < Ordering > ;
1158
1161
1159
1162
/// This method tests less than (for `self` and `other`) and is used by the `<` operator.
@@ -1168,6 +1171,7 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
1168
1171
#[ inline]
1169
1172
#[ must_use]
1170
1173
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
1174
+ #[ cfg_attr( not( bootstrap) , rustc_diagnostic_item = "cmp_partialord_lt" ) ]
1171
1175
fn lt ( & self , other : & Rhs ) -> bool {
1172
1176
matches ! ( self . partial_cmp( other) , Some ( Less ) )
1173
1177
}
@@ -1185,6 +1189,7 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
1185
1189
#[ inline]
1186
1190
#[ must_use]
1187
1191
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
1192
+ #[ cfg_attr( not( bootstrap) , rustc_diagnostic_item = "cmp_partialord_le" ) ]
1188
1193
fn le ( & self , other : & Rhs ) -> bool {
1189
1194
matches ! ( self . partial_cmp( other) , Some ( Less | Equal ) )
1190
1195
}
@@ -1201,6 +1206,7 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
1201
1206
#[ inline]
1202
1207
#[ must_use]
1203
1208
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
1209
+ #[ cfg_attr( not( bootstrap) , rustc_diagnostic_item = "cmp_partialord_gt" ) ]
1204
1210
fn gt ( & self , other : & Rhs ) -> bool {
1205
1211
matches ! ( self . partial_cmp( other) , Some ( Greater ) )
1206
1212
}
@@ -1218,6 +1224,7 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
1218
1224
#[ inline]
1219
1225
#[ must_use]
1220
1226
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
1227
+ #[ cfg_attr( not( bootstrap) , rustc_diagnostic_item = "cmp_partialord_ge" ) ]
1221
1228
fn ge ( & self , other : & Rhs ) -> bool {
1222
1229
matches ! ( self . partial_cmp( other) , Some ( Greater | Equal ) )
1223
1230
}
0 commit comments