@@ -214,7 +214,7 @@ use self::Ordering::*;
214214 append_const_msg,
215215 )
216216) ]
217- #[ cfg_attr ( not ( bootstrap ) , const_trait) ]
217+ #[ const_trait]
218218#[ rustc_diagnostic_item = "PartialEq" ]
219219pub trait PartialEq < Rhs : ?Sized = Self > {
220220 /// This method tests for `self` and `other` values to be equal, and is used
@@ -227,7 +227,6 @@ pub trait PartialEq<Rhs: ?Sized = Self> {
227227 #[ inline]
228228 #[ must_use]
229229 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
230- #[ cfg_attr( bootstrap, default_method_body_is_const) ]
231230 fn ne ( & self , other : & Rhs ) -> bool {
232231 !self . eq ( other)
233232 }
@@ -1054,7 +1053,7 @@ impl PartialOrd for Ordering {
10541053 append_const_msg,
10551054 )
10561055) ]
1057- #[ cfg_attr ( not ( bootstrap ) , const_trait) ]
1056+ #[ const_trait]
10581057#[ rustc_diagnostic_item = "PartialOrd" ]
10591058pub trait PartialOrd < Rhs : ?Sized = Self > : PartialEq < Rhs > {
10601059 /// This method returns an ordering between `self` and `other` values if one exists.
@@ -1098,7 +1097,6 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
10981097 #[ inline]
10991098 #[ must_use]
11001099 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
1101- #[ cfg_attr( bootstrap, default_method_body_is_const) ]
11021100 fn lt ( & self , other : & Rhs ) -> bool {
11031101 matches ! ( self . partial_cmp( other) , Some ( Less ) )
11041102 }
@@ -1118,7 +1116,6 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
11181116 #[ inline]
11191117 #[ must_use]
11201118 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
1121- #[ cfg_attr( bootstrap, default_method_body_is_const) ]
11221119 fn le ( & self , other : & Rhs ) -> bool {
11231120 // Pattern `Some(Less | Eq)` optimizes worse than negating `None | Some(Greater)`.
11241121 // FIXME: The root cause was fixed upstream in LLVM with:
@@ -1141,7 +1138,6 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
11411138 #[ inline]
11421139 #[ must_use]
11431140 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
1144- #[ cfg_attr( bootstrap, default_method_body_is_const) ]
11451141 fn gt ( & self , other : & Rhs ) -> bool {
11461142 matches ! ( self . partial_cmp( other) , Some ( Greater ) )
11471143 }
@@ -1161,7 +1157,6 @@ pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
11611157 #[ inline]
11621158 #[ must_use]
11631159 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
1164- #[ cfg_attr( bootstrap, default_method_body_is_const) ]
11651160 fn ge ( & self , other : & Rhs ) -> bool {
11661161 matches ! ( self . partial_cmp( other) , Some ( Greater | Equal ) )
11671162 }
0 commit comments