@@ -354,7 +354,7 @@ impl<T: ?Sized> Rc<T> {
354354}
355355
356356impl < T : ?Sized , A : Allocator > Rc < T , A > {
357- #[ inline( always) ]
357+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
358358 fn inner ( & self ) -> & RcBox < T > {
359359 // This unsafety is ok because while this Rc is alive we're guaranteed
360360 // that the inner pointer is valid.
@@ -2207,7 +2207,7 @@ impl<T: Copy> RcFromSlice<T> for Rc<[T]> {
22072207impl < T : ?Sized , A : Allocator > Deref for Rc < T , A > {
22082208 type Target = T ;
22092209
2210- #[ inline( always) ]
2210+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
22112211 fn deref ( & self ) -> & T {
22122212 & self . inner ( ) . value
22132213 }
@@ -2453,7 +2453,7 @@ impl<T: ?Sized + PartialOrd, A: Allocator> PartialOrd for Rc<T, A> {
24532453 ///
24542454 /// assert_eq!(Some(Ordering::Less), five.partial_cmp(&Rc::new(6)));
24552455 /// ```
2456- #[ inline( always) ]
2456+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
24572457 fn partial_cmp ( & self , other : & Rc < T , A > ) -> Option < Ordering > {
24582458 ( * * self ) . partial_cmp ( & * * other)
24592459 }
@@ -2471,7 +2471,7 @@ impl<T: ?Sized + PartialOrd, A: Allocator> PartialOrd for Rc<T, A> {
24712471 ///
24722472 /// assert!(five < Rc::new(6));
24732473 /// ```
2474- #[ inline( always) ]
2474+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
24752475 fn lt ( & self , other : & Rc < T , A > ) -> bool {
24762476 * * self < * * other
24772477 }
@@ -2489,7 +2489,7 @@ impl<T: ?Sized + PartialOrd, A: Allocator> PartialOrd for Rc<T, A> {
24892489 ///
24902490 /// assert!(five <= Rc::new(5));
24912491 /// ```
2492- #[ inline( always) ]
2492+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
24932493 fn le ( & self , other : & Rc < T , A > ) -> bool {
24942494 * * self <= * * other
24952495 }
@@ -2507,7 +2507,7 @@ impl<T: ?Sized + PartialOrd, A: Allocator> PartialOrd for Rc<T, A> {
25072507 ///
25082508 /// assert!(five > Rc::new(4));
25092509 /// ```
2510- #[ inline( always) ]
2510+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
25112511 fn gt ( & self , other : & Rc < T , A > ) -> bool {
25122512 * * self > * * other
25132513 }
@@ -2525,7 +2525,7 @@ impl<T: ?Sized + PartialOrd, A: Allocator> PartialOrd for Rc<T, A> {
25252525 ///
25262526 /// assert!(five >= Rc::new(5));
25272527 /// ```
2528- #[ inline( always) ]
2528+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
25292529 fn ge ( & self , other : & Rc < T , A > ) -> bool {
25302530 * * self >= * * other
25312531 }
@@ -3527,24 +3527,24 @@ trait RcInnerPtr {
35273527}
35283528
35293529impl < T : ?Sized > RcInnerPtr for RcBox < T > {
3530- #[ inline( always) ]
3530+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
35313531 fn weak_ref ( & self ) -> & Cell < usize > {
35323532 & self . weak
35333533 }
35343534
3535- #[ inline( always) ]
3535+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
35363536 fn strong_ref ( & self ) -> & Cell < usize > {
35373537 & self . strong
35383538 }
35393539}
35403540
35413541impl < ' a > RcInnerPtr for WeakInner < ' a > {
3542- #[ inline( always) ]
3542+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
35433543 fn weak_ref ( & self ) -> & Cell < usize > {
35443544 self . weak
35453545 }
35463546
3547- #[ inline( always) ]
3547+ #[ cfg_attr ( bootstrap , inline( always) ) ] # [ cfg_attr ( not ( bootstrap ) , inline ( usually ) ) ]
35483548 fn strong_ref ( & self ) -> & Cell < usize > {
35493549 self . strong
35503550 }
0 commit comments