From 4b19b951dd2fb7aa7bc662170c91401f2e8fac3b Mon Sep 17 00:00:00 2001 From: Dirk Van Haerenborgh Date: Fri, 14 Dec 2018 18:45:20 +0100 Subject: remove StreamingIterator again as the iterators don't actually have ownership over items --- tests/main.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'tests/main.rs') diff --git a/tests/main.rs b/tests/main.rs index def2e5f..8a857dd 100644 --- a/tests/main.rs +++ b/tests/main.rs @@ -3,7 +3,6 @@ use notmuch; use std::sync::Arc; -use notmuch::StreamingIteratorExt; use notmuch::{Query, QueryExt, Threads}; fn main() { @@ -30,9 +29,9 @@ fn main() { // let mut threads = db.create_query(&"".to_string()).unwrap().search_threads().unwrap(); - let threads = Arc::new(::search_threads(query).unwrap()); + let mut threads = Arc::new(::search_threads(query).unwrap()); - while let Some(thread) = as StreamingIteratorExt<_>>::next(threads.clone()) + for thread in Arc::get_mut(&mut threads).unwrap() { println!("thread {:?} {:?}", thread.subject(), thread.authors()); } -- cgit v1.2.1