bulbazord added a comment.

We're definitely going to want a test for this, either a shell test or a unit 
test.



================
Comment at: lldb/source/Plugins/ObjectFile/COFF/ObjectFileCOFF.cpp:103-104
+
+  return new ObjectFileCOFF(module_sp, data_sp, data_offset, file, file_offset,
+                            length);
+}
----------------
Reading the implementation of the constructor, it looks like the constructor 
can fail to initialize correctly (specifically `m_object` may not be correctly 
populated). What are callers supposed to do in the way of validation here? 
Maybe there is further validation we can do in this function so that the 
constructor is only invoked if we're absolutely sure it will work?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D149987/new/

https://reviews.llvm.org/D149987

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to