Skip to content

Commit 17ca646

Browse files
authored
Merge pull request #1204 from tinko92/fix/misc-test-warnings
Fixes for miscellaneous gcc/clang warnings in the test suite.
2 parents 64844ce + ead9ea0 commit 17ca646

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

include/boost/geometry/formulas/meridian_direct.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@ class meridian_direct
8484
{
8585
result.reverse_azimuth = pi;
8686
}
87-
else if (result.lat2 < -half_pi &&
88-
result.lat2 > -one_and_a_half_pi)
87+
else if (result.lat2 > -one_and_a_half_pi &&
88+
result.lat2 < -half_pi)
8989
{
9090
result.reverse_azimuth = c0;
9191
}

test/algorithms/buffer/buffer_linestring_geo.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ void test_linestring()
7171
}
7272

7373
settings.test_area = false;
74-
auto const n = sizeof(testcases_aimes) / sizeof(testcases_aimes[0]);
74+
int const n = sizeof(testcases_aimes) / sizeof(testcases_aimes[0]);
7575

7676
// Cases (ouf of 197) where the guessed area estimations are not met.
7777
// If this needs to be changed, be sure to

test/algorithms/buffer/buffer_piece_border.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -161,10 +161,10 @@ void test_point(std::string const& wkt, bool expected_outside,
161161
Point point;
162162
bg::read_wkt(wkt, point);
163163
border.point_on_piece(point, false, false, state);
164-
BOOST_CHECK(expected_outside == state.count > 0);
165-
BOOST_CHECK(expected_on_offsetted == state.count_on_offsetted > 0);
166-
BOOST_CHECK(expected_on_edge == state.count_on_edge > 0);
167-
BOOST_CHECK(expected_on_origin == state.count_on_origin > 0);
164+
BOOST_CHECK(expected_outside == (state.count > 0));
165+
BOOST_CHECK(expected_on_offsetted == (state.count_on_offsetted > 0));
166+
BOOST_CHECK(expected_on_edge == (state.count_on_edge > 0));
167+
BOOST_CHECK(expected_on_origin == (state.count_on_origin > 0));
168168

169169
#ifdef TEST_WITH_SVG
170170
std::string style = "fill:" + color + ";stroke:rgb(0,0,0);stroke-width:1";

test/algorithms/set_operations/intersection/intersection_integer.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ void test_all()
6464
}
6565

6666
template <typename CoordinateType>
67-
void test_ticket_10868(std::string const& wkt_out)
67+
void test_ticket_10868(/*std::string const& wkt_out*/)
6868
{
6969
using point_type = bg::model::point<CoordinateType, 2, bg::cs::cartesian>;
7070
using polygon_type = bg::model::polygon

test/algorithms/set_operations/union/union_issues.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ void issue_1103()
4343
bg::union_(poly1, poly2, result);
4444

4545
// Verify result. Before commit b1bebca the result was empty.
46-
BOOST_CHECK_EQUAL(1, boost::size(result));
46+
BOOST_CHECK_EQUAL(1, static_cast<int>(boost::size(result)));
4747
BOOST_CHECK_CLOSE(2.0, bg::area(result), 0.0001);
4848
}
4949

0 commit comments

Comments
 (0)