@@ -7,6 +7,8 @@ use crate::{
77#[ cfg( feature = "serde" ) ]
88use serde:: { Deserialize , Serialize } ;
99
10+ use alloc:: { vec, vec:: Vec } ;
11+
1012/// Undirected edge type of a [ConstrainedDelaunayTriangulation] (CDT).
1113///
1214/// CDTs need to store if an undirected edge is a constrained edge. To do so, CDTs don't use
@@ -362,7 +364,7 @@ where
362364 VertexOutDirection :: EdgeIntersection ( edge) => edge,
363365 } ;
364366
365- let mut border_loop = std :: collections:: VecDeque :: new ( ) ;
367+ let mut border_loop = alloc :: collections:: VecDeque :: new ( ) ;
366368
367369 border_loop. push_back ( first_edge. rev ( ) . next ( ) . fix ( ) ) ;
368370 border_loop. push_front ( first_edge. rev ( ) . prev ( ) . fix ( ) ) ;
@@ -552,6 +554,8 @@ mod test {
552554 type Cdt = ConstrainedDelaunayTriangulation < Point2 < f64 > > ;
553555 type Delaunay = DelaunayTriangulation < Point2 < f64 > > ;
554556
557+ use alloc:: { vec, vec:: Vec } ;
558+
555559 #[ test]
556560 fn test_add_single_simple_constraint ( ) -> Result < ( ) , InsertionError > {
557561 let mut cdt = Cdt :: new ( ) ;
@@ -657,7 +661,7 @@ mod test {
657661 fn test_add_border_constraint ( ) -> Result < ( ) , InsertionError > {
658662 let points = random_points_with_seed ( 1000 , SEED ) ;
659663 let mut cdt = Cdt :: new ( ) ;
660- let mut max_y = -:: std :: f64:: MAX ;
664+ let mut max_y = -:: core :: f64:: MAX ;
661665 for point in points {
662666 max_y = max_y. max ( point. y ) ;
663667 cdt. insert ( point) ?;
@@ -695,7 +699,8 @@ mod test {
695699 for p in delaunay_points {
696700 d. insert ( p) ?;
697701 }
698- let mut used_vertices = :: std:: collections:: HashSet :: new ( ) ;
702+ let mut used_vertices = :: hashbrown:: HashSet :: new ( ) ;
703+
699704 let mut inserted_constraints = Vec :: new ( ) ;
700705 for v in d. vertices ( ) {
701706 // Insert only edges that do not touch at the end points if
0 commit comments