@@ -309,7 +309,7 @@ pub use once::OnceCell;
309309#[ stable( feature = "rust1" , since = "1.0.0" ) ]
310310#[ repr( transparent) ]
311311#[ rustc_pub_transparent]
312- pub struct Cell < T : ?Sized > {
312+ pub struct Cell < T : ?Sized + ?core :: marker :: Move > {
313313 value : UnsafeCell < T > ,
314314}
315315
@@ -322,7 +322,7 @@ unsafe impl<T: ?Sized> Send for Cell<T> where T: Send {}
322322// having an explicit negative impl is nice for documentation purposes
323323// and results in nicer error messages.
324324#[ stable( feature = "rust1" , since = "1.0.0" ) ]
325- impl < T : ?Sized > !Sync for Cell < T > { }
325+ impl < T : ?Sized + ? crate :: marker :: Move > !Sync for Cell < T > { }
326326
327327#[ stable( feature = "rust1" , since = "1.0.0" ) ]
328328impl < T : Copy > Clone for Cell < T > {
@@ -668,7 +668,7 @@ impl<T: CoerceUnsized<U>, U> CoerceUnsized<Cell<U>> for Cell<T> {}
668668// `self: Cell<&Self>` won't work
669669// `self: CellWrapper<Self>` becomes possible
670670#[ unstable( feature = "dispatch_from_dyn" , issue = "none" ) ]
671- impl < T : DispatchFromDyn < U > , U > DispatchFromDyn < Cell < U > > for Cell < T > { }
671+ impl < T : DispatchFromDyn < U > , U : ? crate :: marker :: Move > DispatchFromDyn < Cell < U > > for Cell < T > { }
672672
673673impl < T > Cell < [ T ] > {
674674 /// Returns a `&[Cell<T>]` from a `&Cell<[T]>`
@@ -2090,12 +2090,12 @@ impl<T: ?Sized + fmt::Display> fmt::Display for RefMut<'_, T> {
20902090#[ stable( feature = "rust1" , since = "1.0.0" ) ]
20912091#[ repr( transparent) ]
20922092#[ rustc_pub_transparent]
2093- pub struct UnsafeCell < T : ?Sized > {
2093+ pub struct UnsafeCell < T : ?Sized + ? crate :: marker :: Move > {
20942094 value : T ,
20952095}
20962096
20972097#[ stable( feature = "rust1" , since = "1.0.0" ) ]
2098- impl < T : ?Sized > !Sync for UnsafeCell < T > { }
2098+ impl < T : ?Sized + ? crate :: marker :: Move > !Sync for UnsafeCell < T > { }
20992099
21002100impl < T > UnsafeCell < T > {
21012101 /// Constructs a new instance of `UnsafeCell` which will wrap the specified
@@ -2359,7 +2359,7 @@ impl<T: CoerceUnsized<U>, U> CoerceUnsized<UnsafeCell<U>> for UnsafeCell<T> {}
23592359// `self: UnsafeCell<&Self>` won't work
23602360// `self: UnsafeCellWrapper<Self>` becomes possible
23612361#[ unstable( feature = "dispatch_from_dyn" , issue = "none" ) ]
2362- impl < T : DispatchFromDyn < U > , U > DispatchFromDyn < UnsafeCell < U > > for UnsafeCell < T > { }
2362+ impl < T : DispatchFromDyn < U > , U : ? crate :: marker :: Move > DispatchFromDyn < UnsafeCell < U > > for UnsafeCell < T > { }
23632363
23642364/// [`UnsafeCell`], but [`Sync`].
23652365///
@@ -2377,7 +2377,7 @@ impl<T: DispatchFromDyn<U>, U> DispatchFromDyn<UnsafeCell<U>> for UnsafeCell<T>
23772377#[ repr( transparent) ]
23782378#[ rustc_diagnostic_item = "SyncUnsafeCell" ]
23792379#[ rustc_pub_transparent]
2380- pub struct SyncUnsafeCell < T : ?Sized > {
2380+ pub struct SyncUnsafeCell < T : ?Sized + ? crate :: marker :: Move > {
23812381 value : UnsafeCell < T > ,
23822382}
23832383
@@ -2466,7 +2466,7 @@ impl<T: CoerceUnsized<U>, U> CoerceUnsized<SyncUnsafeCell<U>> for SyncUnsafeCell
24662466// `self: SyncUnsafeCellWrapper<Self>` becomes possible
24672467#[ unstable( feature = "dispatch_from_dyn" , issue = "none" ) ]
24682468//#[unstable(feature = "sync_unsafe_cell", issue = "95439")]
2469- impl < T : DispatchFromDyn < U > , U > DispatchFromDyn < SyncUnsafeCell < U > > for SyncUnsafeCell < T > { }
2469+ impl < T : DispatchFromDyn < U > , U : ? crate :: marker :: Move > DispatchFromDyn < SyncUnsafeCell < U > > for SyncUnsafeCell < T > { }
24702470
24712471#[ allow( unused) ]
24722472fn assert_coerce_unsized (
0 commit comments