[PATCH] D61117: Fix Bug 41353 - unique symbols printed as D instead of u

George Rimar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon May 13 02:20:11 PDT 2019


grimar added inline comments.


================
Comment at: llvm/tools/llvm-nm/llvm-nm.cpp:1177
+      (!(Obj.isELF() &&
+         (ELFSymbolRef(*I).getBinding() == ELF::STB_GNU_UNIQUE))))
     Ret = toupper(Ret);
----------------
A bit hard to read these conditions.

What do you think about the following?

```
if (!(Symflags & object::SymbolRef::SF_Global))
    return Ret;

if (Obj.isELF() && ELFSymbolRef(*I).getBinding() == ELF::STB_GNU_UNIQUE)
    return Ret;

return toupper(Ret);
```


Repository:
  rL LLVM

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

https://reviews.llvm.org/D61117





More information about the llvm-commits mailing list