From 5efcc16361abd1f45ae2f326dad0535cf3c344e9 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Wed, 26 Nov 2014 15:37:26 +0000 Subject: [PATCH] ranges: const-correctness --- ranges.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ranges.cpp b/ranges.cpp index 46b48ae..4b2535f 100644 --- a/ranges.cpp +++ b/ranges.cpp @@ -82,14 +82,14 @@ iter_range (void *mapv, void (*f) (uint64_t start, uint64_t end, const char *obj extern "C" void find_range (void *mapv, uint64_t start, uint64_t end, void (*f) (uint64_t start, uint64_t end, const char *object, void *opaque), void *opaque) { - ranges *map = (ranges *) mapv; + const ranges *map = (const ranges *) mapv; boost::icl::interval::type window; window = boost::icl::interval::right_open (start, end); - ranges r = *map & window; + const ranges r = *map & window; - ranges::iterator iter = r.begin (); + ranges::const_iterator iter = r.begin (); while (iter != r.end ()) { boost::icl::interval::type range = iter->first; uint64_t start = range.lower (); -- 1.8.3.1