diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-04-11 16:57:37 +0000 |
---|---|---|
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-04-11 16:57:37 +0000 |
commit | d5cc0508904536ff281db13c6a43eba6d1a043f6 (patch) | |
tree | c8d9f3b49931fb54728540b1bc7dc85046d04849 | |
parent | 5adc397fc9f255b883bb14c2dea56f14186cc33c (diff) | |
parent | f5148ad7e332e2b882f019b26c9507d389e797cb (diff) | |
download | unwinding-d5cc0508904536ff281db13c6a43eba6d1a043f6.tar.gz |
Snap for 9919793 from f5148ad7e332e2b882f019b26c9507d389e797cb to udc-d1-release
Change-Id: I90c8a4ceca4ed5350cc634ba5dba766cefc847bc
-rw-r--r-- | libunwindstack/ElfInterfaceArm.h | 9 | ||||
-rw-r--r-- | libunwindstack/include/unwindstack/DwarfSection.h | 9 |
2 files changed, 14 insertions, 4 deletions
diff --git a/libunwindstack/ElfInterfaceArm.h b/libunwindstack/ElfInterfaceArm.h index 6ee6dc9..d8cad48 100644 --- a/libunwindstack/ElfInterfaceArm.h +++ b/libunwindstack/ElfInterfaceArm.h @@ -19,7 +19,6 @@ #include <elf.h> #include <stdint.h> -#include <iterator> #include <unordered_map> #include <unwindstack/ElfInterface.h> @@ -32,8 +31,14 @@ class ElfInterfaceArm : public ElfInterface32 { ElfInterfaceArm(Memory* memory) : ElfInterface32(memory) {} virtual ~ElfInterfaceArm() = default; - class iterator : public std::iterator<std::bidirectional_iterator_tag, uint32_t> { + class iterator { public: + using iterator_category = std::bidirectional_iterator_tag; + using value_type = uint32_t; + using difference_type = std::ptrdiff_t; + using pointer = uint32_t*; + using reference = uint32_t&; + iterator(ElfInterfaceArm* interface, size_t index) : interface_(interface), index_(index) { } iterator& operator++() { index_++; return *this; } diff --git a/libunwindstack/include/unwindstack/DwarfSection.h b/libunwindstack/include/unwindstack/DwarfSection.h index 33435b2..2318f2f 100644 --- a/libunwindstack/include/unwindstack/DwarfSection.h +++ b/libunwindstack/include/unwindstack/DwarfSection.h @@ -18,7 +18,6 @@ #include <stdint.h> -#include <iterator> #include <map> #include <optional> #include <unordered_map> @@ -42,8 +41,14 @@ class DwarfSection { DwarfSection(Memory* memory); virtual ~DwarfSection() = default; - class iterator : public std::iterator<std::bidirectional_iterator_tag, DwarfFde*> { + class iterator { public: + using iterator_category = std::bidirectional_iterator_tag; + using value_type = DwarfFde*; + using difference_type = std::ptrdiff_t; + using pointer = DwarfFde**; + using reference = DwarfFde*&; + iterator(DwarfSection* section, size_t index) : index_(index) { section->GetFdes(&fdes_); if (index_ == static_cast<size_t>(-1)) { |