[PATCH] D63341: [llvm-lipo] Implement -thin
Alexander Shaposhnikov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 19 16:52:26 PDT 2019
alexshap added inline comments.
================
Comment at: llvm/tools/llvm-lipo/llvm-lipo.cpp:300
+ OutFileOrError.get()->getBufferStart());
+ if (OutFileOrError.get()->commit())
+ reportError(OutputFileName, OutFileOrError.get()->commit());
----------------
khm, this works only because the method "commit" has not failed in your tests,
"commit" should not be called twice here. Basically, the correct "pattern" is the following:
if (Error E = OutFileOrError.get()->commit())
reportError(OutputFileName, std::move(E));
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D63341/new/
https://reviews.llvm.org/D63341
More information about the llvm-commits
mailing list