From e874f9237bc631df91f93cb72e5da3c69a6f1c70 Mon Sep 17 00:00:00 2001 From: Dane Springmeyer Date: Tue, 19 Jan 2016 18:06:11 -0800 Subject: [PATCH] silence more gcc shadow/unused warnings --- deps/agg/include/agg_vpgen_clip_polygon.h | 10 ++++----- deps/agg/include/agg_vpgen_clip_polyline.h | 10 ++++----- include/mapnik/offset_converter.hpp | 3 ++- include/mapnik/quad_tree.hpp | 24 +++++++++++----------- 4 files changed, 24 insertions(+), 23 deletions(-) diff --git a/deps/agg/include/agg_vpgen_clip_polygon.h b/deps/agg/include/agg_vpgen_clip_polygon.h index 4972a390b..7f98538e3 100644 --- a/deps/agg/include/agg_vpgen_clip_polygon.h +++ b/deps/agg/include/agg_vpgen_clip_polygon.h @@ -43,12 +43,12 @@ namespace agg { } - void clip_box(double x1, double y1, double x2, double y2) + void clip_box(double _x1, double _y1, double _x2, double _y2) { - m_clip_box.x1 = x1; - m_clip_box.y1 = y1; - m_clip_box.x2 = x2; - m_clip_box.y2 = y2; + m_clip_box.x1 = _x1; + m_clip_box.y1 = _y1; + m_clip_box.x2 = _x2; + m_clip_box.y2 = _y2; m_clip_box.normalize(); } diff --git a/deps/agg/include/agg_vpgen_clip_polyline.h b/deps/agg/include/agg_vpgen_clip_polyline.h index a2e60fa7b..c7b18c98a 100644 --- a/deps/agg/include/agg_vpgen_clip_polyline.h +++ b/deps/agg/include/agg_vpgen_clip_polyline.h @@ -41,12 +41,12 @@ namespace agg { } - void clip_box(double x1, double y1, double x2, double y2) + void clip_box(double _x1, double _y1, double _x2, double _y2) { - m_clip_box.x1 = x1; - m_clip_box.y1 = y1; - m_clip_box.x2 = x2; - m_clip_box.y2 = y2; + m_clip_box.x1 = _x1; + m_clip_box.y1 = _y1; + m_clip_box.x2 = _x2; + m_clip_box.y2 = _y2; m_clip_box.normalize(); } diff --git a/include/mapnik/offset_converter.hpp b/include/mapnik/offset_converter.hpp index a5ac57c3e..d6aabbb58 100644 --- a/include/mapnik/offset_converter.hpp +++ b/include/mapnik/offset_converter.hpp @@ -482,7 +482,8 @@ private: } start_v2.x = v2.x; start_v2.y = v2.y; - bool continue_loop = true; + bool continue_loop; + continue_loop = true; vertex2d tmp_prev(vertex2d::no_init); while (i < points.size()) diff --git a/include/mapnik/quad_tree.hpp b/include/mapnik/quad_tree.hpp index 815fc339b..f6e48c42b 100644 --- a/include/mapnik/quad_tree.hpp +++ b/include/mapnik/quad_tree.hpp @@ -84,12 +84,12 @@ class quad_tree : util::noncopyable int num_subnodes() const { - int count = 0; + int _count = 0; for (int i = 0; i < 4; ++i) { - if (children_[i]) ++count; + if (children_[i]) ++_count; } - return count; + return _count; } ~node () {} }; @@ -165,9 +165,9 @@ public: int count_items() const { - int count = 0; - count_items(root_, count); - return count; + int _count = 0; + count_items(root_, _count); + return _count; } void trim() { @@ -278,23 +278,23 @@ private: if (!n) return 0; else { - int count = 1; + int _count = 1; for (int i = 0; i < 4; ++i) { - count += count_nodes(n->children_[i]); + _count += count_nodes(n->children_[i]); } - return count; + return _count; } } - void count_items(node const* n,int& count) const + void count_items(node const* n, int& _count) const { if (n) { - count += n->cont_.size(); + _count += n->cont_.size(); for (int i = 0; i < 4; ++i) { - count_items(n->children_[i],count); + count_items(n->children_[i],_count); } } }