From e6755865f07f8d9cea8e9481e46bb2635971edbe Mon Sep 17 00:00:00 2001 From: Olek Date: Sat, 31 Dec 2016 02:40:46 +0100 Subject: [PATCH] Fixed warnings --- src/kdtree/mod.rs | 2 +- tests/integration_tests.rs | 4 ---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/src/kdtree/mod.rs b/src/kdtree/mod.rs index 2987a78..eb53f62 100644 --- a/src/kdtree/mod.rs +++ b/src/kdtree/mod.rs @@ -54,7 +54,7 @@ impl Kdtree { /// Can be used if you are sure that the tree is degenerated or if you will never again insert the nodes into the tree. pub fn gather_points_and_rebuild(&mut self) { let mut points : Vec = vec![]; - let nodes = self.gather_points(0,&mut points); + self.gather_points(0,&mut points); self.rebuild_tree(&mut points); } diff --git a/tests/integration_tests.rs b/tests/integration_tests.rs index 5a9a248..0d085c3 100644 --- a/tests/integration_tests.rs +++ b/tests/integration_tests.rs @@ -10,10 +10,6 @@ fn gen_random() -> f64 { rand::thread_rng().gen_range(0., 10000.) } -fn gen_random_usize( max_value : usize) -> usize { - rand::thread_rng().gen_range(0usize, max_value) -} - fn find_nn_with_linear_search<'a>(points : &'a Vec, find_for : Point3WithId) -> &Point3WithId { let distance_fun = kdtree::kdtree::distance::squared_euclidean;