[llvm] [MsgPack] Return an Error instead of bool from readFromBlob (PR #74357)

Alexander Richardson via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 5 10:24:06 PST 2023


================
@@ -5513,41 +5513,42 @@ static AMDNote getAMDNote(uint32_t NoteType, ArrayRef<uint8_t> Desc) {
 struct AMDGPUNote {
   std::string Type;
   std::string Value;
+  bool IsError;
 };
 
 template <typename ELFT>
 static AMDGPUNote getAMDGPUNote(uint32_t NoteType, ArrayRef<uint8_t> Desc) {
----------------
arichardson wrote:

This should still be possible if you return an Expected<> object? We can just print the error string from the bad Expected<> and then continue to the raw dumping?

https://github.com/llvm/llvm-project/pull/74357


More information about the llvm-commits mailing list