We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c441675 commit 23a4050Copy full SHA for 23a4050
library/alloc/src/rc.rs
@@ -2303,7 +2303,7 @@ impl<T: ?Sized> Weak<T> {
2303
}
2304
2305
#[stable(feature = "rc_weak", since = "1.4.0")]
2306
-impl<T: ?Sized> Drop for Weak<T> {
+unsafe impl<#[may_dangle] T: ?Sized> Drop for Weak<T> {
2307
/// Drops the `Weak` pointer.
2308
///
2309
/// # Examples
library/alloc/src/sync.rs
@@ -2015,7 +2015,7 @@ impl<T> Default for Weak<T> {
2015
2016
2017
#[stable(feature = "arc_weak", since = "1.4.0")]
2018
2019
2020
2021
0 commit comments