Droptest
A small crate to help test drop implementation
Documentation
Example
Test if the std::rc::Rc
drop implementation works.
extern crate testdrop;
use TestDrop;
use Rc;
let td = new;
let = td.new_item;
let item = new;
let item_clone = item.clone;
// Decrease the reference counter, but do not drop.
drop;
td.assert_no_drop;
// Decrease the reference counter and then drop.
drop;
td.assert_drop;
License
Licensed under either of
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.