From 23b83f51b703aab2dcc52a63e64c45ece71e2c48 Mon Sep 17 00:00:00 2001 From: kashish2710 Date: Sun, 14 Dec 2025 16:56:46 +0530 Subject: [PATCH 1/4] Add failing regression test for non-overlapping polygon intersection (issue #1439) --- test/algorithms/overlay/overlay_cases.hpp | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/test/algorithms/overlay/overlay_cases.hpp b/test/algorithms/overlay/overlay_cases.hpp index 95b989ce30..1283915297 100644 --- a/test/algorithms/overlay/overlay_cases.hpp +++ b/test/algorithms/overlay/overlay_cases.hpp @@ -1653,4 +1653,24 @@ static std::string mysql_23023665_13[2] = "POLYGON((0 7,-5 6,11 -13,0 7))" }; +// Issue 1439: non-overlapping polygons reported as full intersection +static std::string case_1439[2] = +{ + "POLYGON((-2.47089026 -86.03059246," + "-1.161944873 146.3030596," + "3.40221214 145.8628015," + "3.024695769 141.949088," + "2.420586453 111.9554564," + "1.208013978 -86.04069936," + "-2.47089026 -86.03059246))", + + "POLYGON((-6.213278056 -88.01851748," + "-6.207382255 -86.51852906," + "-6.20539951 -86.01408604," + "-2.470873099 -86.02434575," + "-2.472221358 -86.53315586," + "-2.476196085 -88.03315059," + "-6.213278056 -88.01851748))" +}; + #endif // BOOST_GEOMETRY_TEST_OVERLAY_CASES_HPP From 60ad8e725d89088923e82ae637d8632bd9262eb0 Mon Sep 17 00:00:00 2001 From: kashish2710 Date: Mon, 15 Dec 2025 10:22:18 +0530 Subject: [PATCH 2/4] Add overlay intersection test for case_1439 --- test/algorithms/overlay/overlay.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/algorithms/overlay/overlay.cpp b/test/algorithms/overlay/overlay.cpp index 24272109e9..8e830a523d 100644 --- a/test/algorithms/overlay/overlay.cpp +++ b/test/algorithms/overlay/overlay.cpp @@ -368,6 +368,13 @@ void test_all() // TEST_DIFFERENCE_B(issue_893_multi, 97213916.0, 1, 1); // needs is_traverse + + #ifdef BOOST_GEOMETRY_TEST_ENABLE_FAILING + // Issue 1439 +// Regression test: intersection of non-overlapping polygons should be empty. + TEST_INTERSECTION(case_1439, 0, 0, 0.0); + #endif + TEST_UNION(case_134_multi, 66.0, 1, 2); TEST_UNION(case_76_multi, 8.0, 5, 0); From 2fe18743b3c268a35a6869adb9e82cb2e7f15b4f Mon Sep 17 00:00:00 2001 From: kashish2710 Date: Tue, 23 Dec 2025 15:21:14 +0530 Subject: [PATCH 3/4] Rename case_1439 to issue_1439 --- test/algorithms/overlay/overlay_cases.hpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/test/algorithms/overlay/overlay_cases.hpp b/test/algorithms/overlay/overlay_cases.hpp index 1283915297..50b75cd653 100644 --- a/test/algorithms/overlay/overlay_cases.hpp +++ b/test/algorithms/overlay/overlay_cases.hpp @@ -1653,8 +1653,7 @@ static std::string mysql_23023665_13[2] = "POLYGON((0 7,-5 6,11 -13,0 7))" }; -// Issue 1439: non-overlapping polygons reported as full intersection -static std::string case_1439[2] = +static std::string issue_1439[2] = { "POLYGON((-2.47089026 -86.03059246," "-1.161944873 146.3030596," From 70bbf9d679cff661c291b8adf194516b041aa1f1 Mon Sep 17 00:00:00 2001 From: kashish2710 Date: Tue, 23 Dec 2025 15:23:26 +0530 Subject: [PATCH 4/4] Update overlay test to issue_1439 and fix indentation --- test/algorithms/overlay/overlay.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/test/algorithms/overlay/overlay.cpp b/test/algorithms/overlay/overlay.cpp index 8e830a523d..e22c2595d7 100644 --- a/test/algorithms/overlay/overlay.cpp +++ b/test/algorithms/overlay/overlay.cpp @@ -369,12 +369,9 @@ void test_all() // TEST_DIFFERENCE_B(issue_893_multi, 97213916.0, 1, 1); // needs is_traverse - #ifdef BOOST_GEOMETRY_TEST_ENABLE_FAILING - // Issue 1439 -// Regression test: intersection of non-overlapping polygons should be empty. - TEST_INTERSECTION(case_1439, 0, 0, 0.0); - #endif - +#ifdef BOOST_GEOMETRY_TEST_ENABLE_FAILING + TEST_INTERSECTION(issue_1439, 0, 0, 0.0); +#endif TEST_UNION(case_134_multi, 66.0, 1, 2); TEST_UNION(case_76_multi, 8.0, 5, 0);