@@ -96,6 +96,7 @@ unsafe impl<T: Sync + ?Sized> Send for &T {}
96
96
) ]
97
97
#[ fundamental] // for Default, for example, which requires that `[T]: !Default` be evaluatable
98
98
#[ rustc_specialization_trait]
99
+ #[ cfg_attr( not( bootstrap) , rustc_deny_explicit_impl) ]
99
100
pub trait Sized {
100
101
// Empty.
101
102
}
@@ -127,6 +128,7 @@ pub trait Sized {
127
128
/// [nomicon-coerce]: ../../nomicon/coercions.html
128
129
#[ unstable( feature = "unsize" , issue = "27732" ) ]
129
130
#[ lang = "unsize" ]
131
+ #[ cfg_attr( not( bootstrap) , rustc_deny_explicit_impl) ]
130
132
pub trait Unsize < T : ?Sized > {
131
133
// Empty.
132
134
}
@@ -693,6 +695,7 @@ impl<T: ?Sized> StructuralEq for PhantomData<T> {}
693
695
reason = "this trait is unlikely to ever be stabilized, use `mem::discriminant` instead"
694
696
) ]
695
697
#[ lang = "discriminant_kind" ]
698
+ #[ cfg_attr( not( bootstrap) , rustc_deny_explicit_impl) ]
696
699
pub trait DiscriminantKind {
697
700
/// The type of the discriminant, which must satisfy the trait
698
701
/// bounds required by `mem::Discriminant`.
@@ -793,6 +796,7 @@ impl<T: ?Sized> Unpin for *mut T {}
793
796
#[ lang = "destruct" ]
794
797
#[ rustc_on_unimplemented( message = "can't drop `{Self}`" , append_const_msg) ]
795
798
#[ const_trait]
799
+ #[ cfg_attr( not( bootstrap) , rustc_deny_explicit_impl) ]
796
800
pub trait Destruct { }
797
801
798
802
/// A marker for tuple types.
@@ -802,6 +806,7 @@ pub trait Destruct {}
802
806
#[ unstable( feature = "tuple_trait" , issue = "none" ) ]
803
807
#[ lang = "tuple_trait" ]
804
808
#[ rustc_on_unimplemented( message = "`{Self}` is not a tuple" ) ]
809
+ #[ cfg_attr( not( bootstrap) , rustc_deny_explicit_impl) ]
805
810
pub trait Tuple { }
806
811
807
812
/// Implementations of `Copy` for primitive types.
0 commit comments