File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,12 @@ impl<T: ?Sized> !Send for *const T {}
4444#[ stable( feature = "rust1" , since = "1.0.0" ) ]
4545impl < T : ?Sized > !Send for * mut T { }
4646
47+ // Most instances arise automatically, but this instance is needed to link up `T: Sync` with
48+ // `&T: Send` (and it also removes the unsound default instance `T Send` -> `&T: Send` that would
49+ // otherwise exist).
50+ #[ stable( feature = "rust1" , since = "1.0.0" ) ]
51+ unsafe impl < T : Sync + ?Sized > Send for & T { }
52+
4753/// Types with a constant size known at compile time.
4854///
4955/// All type parameters have an implicit bound of `Sized`. The special syntax
@@ -680,13 +686,6 @@ pub struct PhantomData<T: ?Sized>;
680686
681687impls ! { PhantomData }
682688
683- mod impls {
684- #[ stable( feature = "rust1" , since = "1.0.0" ) ]
685- unsafe impl < T : Sync + ?Sized > Send for & T { }
686- #[ stable( feature = "rust1" , since = "1.0.0" ) ]
687- unsafe impl < T : Send + ?Sized > Send for & mut T { }
688- }
689-
690689/// Compiler-internal trait used to indicate the type of enum discriminants.
691690///
692691/// This trait is automatically implemented for every type and does not add any
You can’t perform that action at this time.
0 commit comments