|
5 | 5 |
|
6 | 6 | This file is part of Osmium (https://osmcode.org/libosmium). |
7 | 7 |
|
8 | | -Copyright 2013-2025 Jochen Topf <jochen@topf.org> and others (see README). |
| 8 | +Copyright 2013-2026 Jochen Topf <jochen@topf.org> and others (see README). |
9 | 9 |
|
10 | 10 | Boost Software License - Version 1.0 - August 17th, 2003 |
11 | 11 |
|
@@ -290,7 +290,7 @@ namespace osmium { |
290 | 290 | } |
291 | 291 | } |
292 | 292 |
|
293 | | - ProtoRing* find_enclosing_ring(NodeRefSegment* segment) { |
| 293 | + ProtoRing* find_enclosing_ring(NodeRefSegment const* segment) { |
294 | 294 | if (debug()) { |
295 | 295 | std::cerr << " Looking for ring enclosing " << *segment << "\n"; |
296 | 296 | } |
@@ -553,7 +553,7 @@ namespace osmium { |
553 | 553 | return; |
554 | 554 | } |
555 | 555 |
|
556 | | - std::stable_sort(rings.begin(), rings.end(), [](ProtoRing* a, ProtoRing* b) { |
| 556 | + std::stable_sort(rings.begin(), rings.end(), [](ProtoRing const* a, ProtoRing const* b) { |
557 | 557 | return a->min_segment() < b->min_segment(); |
558 | 558 | }); |
559 | 559 |
|
@@ -824,7 +824,7 @@ namespace osmium { |
824 | 824 | }); |
825 | 825 |
|
826 | 826 | find_inner_outer_complex(); |
827 | | - ProtoRing* outer_ring = find_enclosing_ring(ring_min->ring().min_segment()); |
| 827 | + const ProtoRing* outer_ring = find_enclosing_ring(ring_min->ring().min_segment()); |
828 | 828 | const bool ring_min_is_outer = !outer_ring; |
829 | 829 | if (debug()) { |
830 | 830 | std::cerr << " Open ring is " << (ring_min_is_outer ? "outer" : "inner") << " ring\n"; |
@@ -858,7 +858,7 @@ namespace osmium { |
858 | 858 | if (!open_ring_its.empty()) { |
859 | 859 | ++m_stats.open_rings; |
860 | 860 | if (m_config.problem_reporter) { |
861 | | - for (auto& it : open_ring_its) { |
| 861 | + for (const auto& it : open_ring_its) { |
862 | 862 | m_config.problem_reporter->report_ring_not_closed(it->get_node_ref_start(), nullptr); |
863 | 863 | m_config.problem_reporter->report_ring_not_closed(it->get_node_ref_stop(), nullptr); |
864 | 864 | } |
@@ -912,7 +912,7 @@ namespace osmium { |
912 | 912 | [this, &location](const slocation& lhs, const slocation& rhs) { |
913 | 913 | return lhs.location(m_segment_list, location) < rhs.location(m_segment_list, location); |
914 | 914 | })); |
915 | | - for (auto& loc : locs) { |
| 915 | + for (const auto& loc : locs) { |
916 | 916 | if (!m_segment_list[loc.item].is_done()) { |
917 | 917 | count_remaining -= add_new_ring_complex(loc); |
918 | 918 | if (count_remaining == 0) { |
|
0 commit comments