@@ -264,6 +264,7 @@ use core::ops::{CoerceUnsized, Deref, DerefMut, DerefPure, DispatchFromDyn, Rece
264264use core:: panic:: { RefUnwindSafe , UnwindSafe } ;
265265#[ cfg( not( no_global_oom_handling) ) ]
266266use core:: pin:: Pin ;
267+ use core:: pin:: PinCoerceUnsized ;
267268use core:: ptr:: { self , drop_in_place, NonNull } ;
268269#[ cfg( not( no_global_oom_handling) ) ]
269270use core:: slice:: from_raw_parts_mut;
@@ -2181,6 +2182,9 @@ impl<T: ?Sized, A: Allocator> Deref for Rc<T, A> {
21812182 }
21822183}
21832184
2185+ #[ unstable( feature = "pin_coerce_unsized_trait" , issue = "123430" ) ]
2186+ unsafe impl < T : ?Sized , A : Allocator > PinCoerceUnsized for Rc < T , A > { }
2187+
21842188#[ unstable( feature = "deref_pure_trait" , issue = "87121" ) ]
21852189unsafe impl < T : ?Sized , A : Allocator > DerefPure for Rc < T , A > { }
21862190
@@ -3696,6 +3700,9 @@ impl<T: ?Sized, A: Allocator> Deref for UniqueRc<T, A> {
36963700 }
36973701}
36983702
3703+ #[ unstable( feature = "pin_coerce_unsized_trait" , issue = "123430" ) ]
3704+ unsafe impl < T : ?Sized > PinCoerceUnsized for UniqueRc < T > { }
3705+
36993706#[ unstable( feature = "unique_rc_arc" , issue = "112566" ) ]
37003707impl < T : ?Sized , A : Allocator > DerefMut for UniqueRc < T , A > {
37013708 fn deref_mut ( & mut self ) -> & mut T {
0 commit comments