[PATCH] D77289: [Object] Fix crash caused by unhandled error.

George Rimar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 3 01:34:54 PDT 2020


grimar added a comment.

I'd also recommend to start using "Edit related revisions" on the right panel of the phab.
Then you should be able to edit related parent/child revisions, because currently it is unobvious which dependencies your patches has.



================
Comment at: llvm/include/llvm/Object/ELFObjectFile.h:631
+    if (Expected<Elf_Sym_Range> SymbolsOrErr = EF.symbols(Sec)) {
+      if (ESym == SymbolsOrErr->begin())
+        return true;
----------------
grimar wrote:
> grimar wrote:
> > This condition needs a comment to explain what it does.
> And probably no need to add a comment then as `IsNullSymbol` describes nicely what the code does.
`IsNullSymbol`, not `IsNULLSymbol`

(if you search for "IsNULL" in LLVM's code, you'll see 0 matching lines, but "IsNull" gives a lot of.
So having `NULL` is at least inconsistent).


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D77289





More information about the llvm-commits mailing list