Revert "Convert libstd to use the Drop trait"
This reverts commit 28c7a25151.
This commit is contained in:
@@ -217,10 +217,7 @@ fn check_poison(is_mutex: bool, failed: bool) {
|
||||
#[doc(hidden)]
|
||||
struct PoisonOnFail {
|
||||
failed: &mut bool,
|
||||
}
|
||||
|
||||
impl PoisonOnFail : Drop {
|
||||
fn finalize() {
|
||||
drop {
|
||||
/* assert !*self.failed; -- might be false in case of cond.wait() */
|
||||
if task::failing() { *self.failed = true; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user