[PATCH] D106783: [AIX][XCOFF][llvm-readobj] Replace unwrapOrError with reportUniqueWarning
James Henderson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 27 00:29:30 PDT 2021
jhenderson added inline comments.
================
Comment at: llvm/tools/llvm-readobj/XCOFFDumper.cpp:139
+ if (Error E = ErrOrRelocations.takeError())
+ reportUniqueWarning(std::move(E));
+
----------------
1) Is this tested?
2) You'll need to break out of or continue this loop here, as `*ErrOrRelocations` will result in referencing invalid memory if there is an error. (reportUniqueWarning reports the warning and continues).
================
Comment at: llvm/tools/llvm-readobj/XCOFFDumper.cpp:151
+ if (Error E = ErrOrSymbolName.takeError())
+ reportUniqueWarning(std::move(E));
----------------
Same comments as above.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D106783/new/
https://reviews.llvm.org/D106783
More information about the llvm-commits
mailing list