diff --git a/Mesh_2/include/CGAL/Mesh_2/Mesh_global_optimizer_2.h b/Mesh_2/include/CGAL/Mesh_2/Mesh_global_optimizer_2.h index f4cd82f12d1..0ffcca179cc 100644 --- a/Mesh_2/include/CGAL/Mesh_2/Mesh_global_optimizer_2.h +++ b/Mesh_2/include/CGAL/Mesh_2/Mesh_global_optimizer_2.h @@ -352,7 +352,7 @@ private: sum += CGAL::sqrt(*it); #ifdef CGAL_MESH_2_OPTIMIZER_VERBOSE - sum_moves_ = sum/big_moves_.size(); + sum_moves_ = sum/FT(big_moves_.size()); #endif return ( sum/FT(big_moves_.size()) < convergence_ratio_ ); diff --git a/Mesh_2/include/CGAL/Mesh_2/Mesh_sizing_field.h b/Mesh_2/include/CGAL/Mesh_2/Mesh_sizing_field.h index 098e8b4c5ba..94236ba7ea0 100644 --- a/Mesh_2/include/CGAL/Mesh_2/Mesh_sizing_field.h +++ b/Mesh_2/include/CGAL/Mesh_2/Mesh_sizing_field.h @@ -169,7 +169,7 @@ private: typename Tr::Edge_circulator end = ec; FT sum_len(0.); - FT nb = 0.; + unsigned int nb = 0; do { Edge e = *ec; @@ -187,7 +187,7 @@ private: while(++ec != end); // nb == 0 could happen if there is an isolated point. if( 0 != nb ) - return sum_len/nb; + return sum_len/FT(nb); else // Use outside faces to compute size of point return 1.;//todo