summaryrefslogtreecommitdiffstats
path: root/llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
diff options
context:
space:
mode:
authorFangrui Song <maskray@google.com>2019-04-12 02:02:06 +0000
committerFangrui Song <maskray@google.com>2019-04-12 02:02:06 +0000
commitcecc4352508928f7ceeeee92fcde2986a5c55535 (patch)
treefd00bcfc8259cefe24787b0c848cedd79ff9137f /llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
parent21375ca136025f2a6dc55418d43630455ca0e98b (diff)
downloadbcm5719-llvm-cecc4352508928f7ceeeee92fcde2986a5c55535.tar.gz
bcm5719-llvm-cecc4352508928f7ceeeee92fcde2986a5c55535.zip
Use llvm::lower_bound. NFC
This reapplies rL358161. That commit inadvertently reverted an exegesis file to an old version. llvm-svn: 358246
Diffstat (limited to 'llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp')
-rw-r--r--llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp b/llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
index 6bac12f765d..7c80b3bb3e9 100644
--- a/llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
+++ b/llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
@@ -57,8 +57,8 @@ void DWARFDebugLoc::LocationList::dump(raw_ostream &OS, bool IsLittleEndian,
DWARFDebugLoc::LocationList const *
DWARFDebugLoc::getLocationListAtOffset(uint64_t Offset) const {
- auto It = std::lower_bound(
- Locations.begin(), Locations.end(), Offset,
+ auto It = llvm::lower_bound(
+ Locations, Offset,
[](const LocationList &L, uint64_t Offset) { return L.Offset < Offset; });
if (It != Locations.end() && It->Offset == Offset)
return &(*It);
@@ -213,8 +213,8 @@ void DWARFDebugLoclists::parse(DataExtractor data, unsigned Version) {
DWARFDebugLoclists::LocationList const *
DWARFDebugLoclists::getLocationListAtOffset(uint64_t Offset) const {
- auto It = std::lower_bound(
- Locations.begin(), Locations.end(), Offset,
+ auto It = llvm::lower_bound(
+ Locations, Offset,
[](const LocationList &L, uint64_t Offset) { return L.Offset < Offset; });
if (It != Locations.end() && It->Offset == Offset)
return &(*It);
OpenPOWER on IntegriCloud