[objdump] Make iterator operator* return a reference.

This is closer to the expected behavior of an iterator and avoids awkward
warnings from clang's -Wrange-loop-analysis below.

llvm-svn: 248497
This commit is contained in:
Benjamin Kramer
2015-09-24 14:52:52 +00:00
parent 72e64317a7
commit ac9257b258

View File

@@ -189,7 +189,7 @@ public:
: Predicate(P), Iterator(I), End(E) {
ScanPredicate();
}
llvm::object::SectionRef operator*() const { return *Iterator; }
const llvm::object::SectionRef &operator*() const { return *Iterator; }
SectionFilterIterator &operator++() {
++Iterator;
ScanPredicate();