Revert "Convert libstd to use the Drop trait"

This reverts commit 28c7a25151.
This commit is contained in:
Brian Anderson
2012-11-14 14:51:16 -08:00
parent 11024eaebb
commit c44c9a47d8
8 changed files with 52 additions and 107 deletions

View File

@@ -39,15 +39,12 @@ pub enum CVec<T> {
struct DtorRes {
dtor: Option<fn@()>,
}
impl DtorRes : Drop {
fn finalize() {
drop {
match self.dtor {
option::None => (),
option::Some(f) => f()
}
}
}
}
fn DtorRes(dtor: Option<fn@()>) -> DtorRes {