================ @@ -154,3 +155,17 @@ MinidumpFile::create(MemoryBufferRef Source) { return std::unique_ptr<MinidumpFile>( new MinidumpFile(Source, Hdr, *ExpectedStreams, std::move(StreamMap))); } + +Expected<ArrayRef<MemoryDescriptor_64>> MinidumpFile::getMemory64List() const { + Expected<minidump::Memory64ListHeader> MemoryList64 = getMemoryList64Header(); + if (!MemoryList64) + return MemoryList64.takeError(); + + std::optional<ArrayRef<uint8_t>> Stream = + getRawStream(StreamType::Memory64List); + if (!Stream) + return createError("No such stream"); + + return getDataSliceAs<minidump::MemoryDescriptor_64>( ---------------- Jlalond wrote:
I was a bit flippant, but I think the only confusion for me is that the pointers are always being converted to an ArrayRef, `getDataSliceAsArrayOf<>` could work but is particularly verbose https://github.com/llvm/llvm-project/pull/101086 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits