}
}
-
#[test]
fn iterator_collect() {
let arr = [0, 1, 2, 5, 9];
#[test]
fn iterator_debug() {
let arr = [0, 1, 2, 5, 9];
- assert_eq!(
- format!("{:?}", IntoIter::new(arr)),
- "IntoIter([0, 1, 2, 5, 9])",
- );
+ assert_eq!(format!("{:?}", IntoIter::new(arr)), "IntoIter([0, 1, 2, 5, 9])",);
}
#[test]
struct Foo<'a>(&'a Cell<usize>);
impl Drop for Foo<'_> {
- fn drop(&mut self) {
+ fn drop(&mut self) {
self.0.set(self.0.get() + 1);
}
}