[llvm] [XCOFF]refactor isFunction, NFC (PR #72232)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 14 06:49:56 PST 2023
================
@@ -1253,12 +1253,8 @@ bool XCOFFSymbolRef::isFunction() const {
const int16_t SectNum = getSectionNumber();
Expected<DataRefImpl> SI = getObject()->getSectionByNum(SectNum);
- if (!SI) {
- // If we could not get the section, then this symbol should not be
- // a function. So consume the error and return `false` to move on.
- consumeError(SI.takeError());
- return false;
- }
+ if (Error E = SI.takeError())
----------------
diggerlin wrote:
ditto
https://github.com/llvm/llvm-project/pull/72232
More information about the llvm-commits
mailing list