diff --git a/src/lib.rs b/src/lib.rs index c5d500e..2560712 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -417,7 +417,7 @@ impl SearchPool { } } -impl Layer for Vec { +impl Layer for [ZeroNode] { fn nearest_iter(&self, pid: PointId) -> NearestIter<'_> { NearestIter { nearest: &self[pid.0 as usize].nearest, @@ -425,7 +425,7 @@ impl Layer for Vec { } } -impl Layer for Vec { +impl Layer for [UpperNode] { fn nearest_iter(&self, pid: PointId) -> NearestIter<'_> { NearestIter { nearest: &self[pid.0 as usize].nearest, @@ -503,7 +503,7 @@ impl Search { fn select_heuristic( &mut self, - layer: &Vec, + layer: &[ZeroNode], num: usize, point: &P, points: &[P],