Skip to content
/ rust Public
forked from rust-lang/rust

Commit 98c85a3

Browse files
authored
Rollup merge of rust-lang#138477 - compiler-errors:deny-bikeshed-guaranteed-no-drop, r=lcnr
Deny impls for `BikeshedGuaranteedNoDrop` r? lcnr
2 parents 3ec4d0e + 4c32adb commit 98c85a3

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Diff for: library/core/src/marker.rs

+5-1
Original file line numberDiff line numberDiff line change
@@ -465,9 +465,13 @@ impl<T: ?Sized> Copy for &T {}
465465
/// Notably, this doesn't include all trivially-destructible types for semver
466466
/// reasons.
467467
///
468-
/// Bikeshed name for now.
468+
/// Bikeshed name for now. This trait does not do anything other than reflect the
469+
/// set of types that are allowed within unions for field validity.
469470
#[unstable(feature = "bikeshed_guaranteed_no_drop", issue = "none")]
470471
#[lang = "bikeshed_guaranteed_no_drop"]
472+
#[rustc_deny_explicit_impl]
473+
#[rustc_do_not_implement_via_object]
474+
#[doc(hidden)]
471475
pub trait BikeshedGuaranteedNoDrop {}
472476

473477
/// Types for which it is safe to share references between threads.

0 commit comments

Comments
 (0)