diff options
author | Raphael Isemann <teemperor@gmail.com> | 2019-12-06 09:53:44 +0100 |
---|---|---|
committer | Raphael Isemann <teemperor@gmail.com> | 2019-12-06 10:19:20 +0100 |
commit | 777d1f7272b52cbe372e7234a7247b189e416062 (patch) | |
tree | 84c0126ef89c2e3759b8fc9164ef8c70991a1772 | |
parent | 0d2472ff6f604af842059d9a0098db274515a2d3 (diff) | |
download | bcm5719-llvm-777d1f7272b52cbe372e7234a7247b189e416062.tar.gz bcm5719-llvm-777d1f7272b52cbe372e7234a7247b189e416062.zip |
[lldb] Migrate VMRange::Dump to raw_ostream
-rw-r--r-- | lldb/include/lldb/Utility/VMRange.h | 7 | ||||
-rw-r--r-- | lldb/source/Core/Section.cpp | 2 | ||||
-rw-r--r-- | lldb/source/Expression/DWARFExpression.cpp | 2 | ||||
-rw-r--r-- | lldb/source/Utility/VMRange.cpp | 7 |
4 files changed, 8 insertions, 10 deletions
diff --git a/lldb/include/lldb/Utility/VMRange.h b/lldb/include/lldb/Utility/VMRange.h index 9c2f9d09091..72f859b6758 100644 --- a/lldb/include/lldb/Utility/VMRange.h +++ b/lldb/include/lldb/Utility/VMRange.h @@ -10,16 +10,13 @@ #define liblldb_VMRange_h_ #include "lldb/lldb-types.h" +#include "llvm/Support/raw_ostream.h" #include <stddef.h> #include <stdint.h> #include <vector> namespace lldb_private { -class Stream; -} - -namespace lldb_private { // A vm address range. These can represent offsets ranges or actual // addresses. @@ -81,7 +78,7 @@ public: return false; } - void Dump(Stream *s, lldb::addr_t base_addr = 0, + void Dump(llvm::raw_ostream &s, lldb::addr_t base_addr = 0, uint32_t addr_width = 8) const; static bool ContainsValue(const VMRange::collection &coll, diff --git a/lldb/source/Core/Section.cpp b/lldb/source/Core/Section.cpp index e8fcca4603d..4a9acab2e27 100644 --- a/lldb/source/Core/Section.cpp +++ b/lldb/source/Core/Section.cpp @@ -323,7 +323,7 @@ void Section::Dump(Stream *s, Target *target, uint32_t depth) const { } VMRange range(addr, addr + m_byte_size); - range.Dump(s, 0); + range.Dump(s->AsRawOstream(), 0); } s->Printf("%c %c%c%c 0x%8.8" PRIx64 " 0x%8.8" PRIx64 " 0x%8.8x ", diff --git a/lldb/source/Expression/DWARFExpression.cpp b/lldb/source/Expression/DWARFExpression.cpp index df31d15e7d5..1297255a38b 100644 --- a/lldb/source/Expression/DWARFExpression.cpp +++ b/lldb/source/Expression/DWARFExpression.cpp @@ -131,7 +131,7 @@ void DWARFExpression::GetDescription(Stream *s, lldb::DescriptionLevel level, s->PutCString(", "); VMRange addr_range(curr_base_addr + begin_addr_offset, curr_base_addr + end_addr_offset); - addr_range.Dump(s, 0, 8); + addr_range.Dump(s->AsRawOstream(), 0, 8); s->PutChar('{'); lldb::offset_t location_length = m_data.GetU16(&offset); DumpLocation(s, offset, location_length, level, abi); diff --git a/lldb/source/Utility/VMRange.cpp b/lldb/source/Utility/VMRange.cpp index e7c6b0bcccb..c8c3334138d 100644 --- a/lldb/source/Utility/VMRange.cpp +++ b/lldb/source/Utility/VMRange.cpp @@ -35,9 +35,10 @@ bool VMRange::ContainsRange(const VMRange::collection &coll, }) != coll.end(); } -void VMRange::Dump(Stream *s, lldb::addr_t offset, uint32_t addr_width) const { - DumpAddressRange(s->AsRawOstream(), offset + GetBaseAddress(), - offset + GetEndAddress(), addr_width); +void VMRange::Dump(llvm::raw_ostream &s, lldb::addr_t offset, + uint32_t addr_width) const { + DumpAddressRange(s, offset + GetBaseAddress(), offset + GetEndAddress(), + addr_width); } bool lldb_private::operator==(const VMRange &lhs, const VMRange &rhs) { |