We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 191ff2d commit 3385fbaCopy full SHA for 3385fba
src/libcore/ops.rs
@@ -95,6 +95,16 @@ use fmt;
95
#[stable(feature = "rust1", since = "1.0.0")]
96
pub trait Drop {
97
/// A method called when the value goes out of scope.
98
+ ///
99
+ /// When this method has been called, `self` has not yet been deallocated.
100
+ /// If it were, `self` would be a dangling reference.
101
102
+ /// After this function is over, the memory of `self` will be deallocated.
103
104
+ /// # Panics
105
106
+ /// Given that a `panic!` will call `drop()` as it unwinds, any `panic!` in
107
+ /// a `drop()` implementation will likely abort.
108
109
fn drop(&mut self);
110
}
0 commit comments