================
@@ -550,7 +588,7 @@ Stream::create(const Directory &StreamDesc, const 
object::MinidumpFile &File) {
   llvm_unreachable("Unhandled stream kind!");
 }
 
-Expected<Object> Object::create(const object::MinidumpFile &File) {
+Expected<Object> Object::create(object::MinidumpFile &File) {
----------------
labath wrote:

Yeah, this doesn't seem completely ideal. Looking at the code, it looks like 
the only place where you're accessing these, is when you're iterating over them 
anyway, so maybe some sort of an iterator would be in order?

It could store the current offset in its state without modifying the underlying 
container. And perhaps its value_type could be `std::pair<MemoryDescriptor_64, 
ArrayRef<uint8_t>>` ? It might also need to be an `llvm::fallible_iterator` so 
it can report errors it encounters mid-flight.

https://github.com/llvm/llvm-project/pull/101272
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to