From d463240d8fd961d45b47ba96e0d93c37e1719da7 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Wed, 21 Nov 2012 09:55:55 +1100 Subject: code cleanup: quiet warnings with gcc. (bzr r11888) --- src/libavoid/orthogonal.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/libavoid/orthogonal.cpp') diff --git a/src/libavoid/orthogonal.cpp b/src/libavoid/orthogonal.cpp index e0a30b246..772fc9668 100644 --- a/src/libavoid/orthogonal.cpp +++ b/src/libavoid/orthogonal.cpp @@ -204,7 +204,7 @@ class ShiftSegment }; typedef std::list ShiftSegmentList; -bool cmpShiftSegment(const ShiftSegment& u, const ShiftSegment& v) +static bool cmpShiftSegment(const ShiftSegment& u, const ShiftSegment& v) { return u < v; } @@ -488,7 +488,7 @@ Event **events; // Used for quicksort. Must return <0, 0, or >0. -int compare_events(const void *a, const void *b) +static int compare_events(const void *a, const void *b) { Event *ea = *(Event**) a; Event *eb = *(Event**) b; -- cgit v1.2.3 From cfe9c94712a2ff6849b123672e51b603f20e76ae Mon Sep 17 00:00:00 2001 From: "Jon A. Cruz" Date: Thu, 10 Jan 2013 23:30:09 -0800 Subject: Warning and dead code cleanup. (bzr r12014) --- src/libavoid/orthogonal.cpp | 6 ------ 1 file changed, 6 deletions(-) (limited to 'src/libavoid/orthogonal.cpp') diff --git a/src/libavoid/orthogonal.cpp b/src/libavoid/orthogonal.cpp index 772fc9668..d0a899252 100644 --- a/src/libavoid/orthogonal.cpp +++ b/src/libavoid/orthogonal.cpp @@ -204,12 +204,6 @@ class ShiftSegment }; typedef std::list ShiftSegmentList; -static bool cmpShiftSegment(const ShiftSegment& u, const ShiftSegment& v) -{ - return u < v; -} - - struct Node; struct CmpNodePos { bool operator()(const Node* u, const Node* v) const; }; -- cgit v1.2.3 From 76137247c241a931292bd559e6575c34bd877d9f Mon Sep 17 00:00:00 2001 From: Kris De Gussem Date: Sun, 13 Oct 2013 18:12:29 +0200 Subject: cppcheck (bzr r12681) --- src/libavoid/orthogonal.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/libavoid/orthogonal.cpp') diff --git a/src/libavoid/orthogonal.cpp b/src/libavoid/orthogonal.cpp index d0a899252..b5ef8d7e8 100644 --- a/src/libavoid/orthogonal.cpp +++ b/src/libavoid/orthogonal.cpp @@ -1510,7 +1510,7 @@ extern void generateStaticOrthogonalVisGraph(Router *router) const int pass = 1; processEventVert(router, scanline, segments, events[i], pass); } - COLA_ASSERT(scanline.size() == 0); + COLA_ASSERT(scanline.empty()); for (unsigned i = 0; i < totalEvents; ++i) { delete events[i]; @@ -1589,7 +1589,7 @@ extern void generateStaticOrthogonalVisGraph(Router *router) const int pass = 1; processEventHori(router, scanline, vertSegments, events[i], pass); } - COLA_ASSERT(scanline.size() == 0); + COLA_ASSERT(scanline.empty()); for (unsigned i = 0; i < totalEvents; ++i) { delete events[i]; @@ -1879,7 +1879,7 @@ static void buildOrthogonalChannelInfo(Router *router, processShiftEvent(router, scanline, segmentList, events[i], dim, pass); } - COLA_ASSERT(scanline.size() == 0); + COLA_ASSERT(scanline.empty()); for (unsigned i = 0; i < totalEvents; ++i) { delete events[i]; -- cgit v1.2.3