From 0c3228e589bd51ea725969100f21dfa85e4bca3f Mon Sep 17 00:00:00 2001 From: Vissarion Fisikopoulos Date: Mon, 14 Apr 2025 14:51:07 +0300 Subject: [PATCH] fix: Compilation errors and warnings in examples --- example/07_a_graph_route_example.cpp | 5 ++--- example/07_b_graph_route_example.cpp | 5 ++--- example/c04_a_custom_triangle_example.cpp | 2 +- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/example/07_a_graph_route_example.cpp b/example/07_a_graph_route_example.cpp index 1b6786771..6d0741277 100644 --- a/example/07_a_graph_route_example.cpp +++ b/example/07_a_graph_route_example.cpp @@ -17,11 +17,11 @@ #include #include -#include +#include #include - #include #include +#include #include #include @@ -46,7 +46,6 @@ void read_wkt(std::string const& filename, std::vector& tuples, Box& box) { std::string line; std::getline(cpp_file, line); - Geometry geometry; boost::trim(line); if (! line.empty() && ! boost::starts_with(line, "#")) { diff --git a/example/07_b_graph_route_example.cpp b/example/07_b_graph_route_example.cpp index ca39839e7..c2156abaa 100644 --- a/example/07_b_graph_route_example.cpp +++ b/example/07_b_graph_route_example.cpp @@ -21,11 +21,11 @@ #include #include -#include +#include #include - #include #include +#include #include #include @@ -51,7 +51,6 @@ void read_wkt(std::string const& filename, std::vector& tuples, Box& box) { std::string line; std::getline(cpp_file, line); - Geometry geometry; boost::trim(line); if (! line.empty() && ! boost::starts_with(line, "#")) { diff --git a/example/c04_a_custom_triangle_example.cpp b/example/c04_a_custom_triangle_example.cpp index 5b255e421..4ef5e6118 100644 --- a/example/c04_a_custom_triangle_example.cpp +++ b/example/c04_a_custom_triangle_example.cpp @@ -41,7 +41,7 @@ BOOST_GEOMETRY_REGISTER_RING(triangle) namespace boost { namespace geometry { template<> -inline double area(const triangle& t) +inline auto area(const triangle& t) { /* C / \