[all-commits] [llvm/llvm-project] 3ae27f: [MC][ELF] Fix gcc "enumeral and non-enumeral type ...

nullptr-cpp via All-commits all-commits at lists.llvm.org
Wed Feb 17 22:59:52 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 3ae27fca7ea584222bb93019d12bc79f2ada64f0
      https://github.com/llvm/llvm-project/commit/3ae27fca7ea584222bb93019d12bc79f2ada64f0
  Author: Yang Fan <nullptr.cpp at gmail.com>
  Date:   2021-02-18 (Thu, 18 Feb 2021)

  Changed paths:
    M llvm/lib/MC/ELFObjectWriter.cpp

  Log Message:
  -----------
  [MC][ELF] Fix gcc "enumeral and non-enumeral type in conditional expression" warning (NFC)

GCC warning:
```
/llvm-project/llvm/lib/MC/ELFObjectWriter.cpp: In member function ‘uint64_t {anonymous}::ELFWriter::writeObject(llvm::MCAssembler&, const llvm::MCAsmLayout&)’:
/llvm-project/llvm/lib/MC/ELFObjectWriter.cpp:1137:38: warning: enumeral and non-enumeral type in conditional expression [-Wextra]
 1137 |     write(uint32_t(Group->isComdat() ? ELF::GRP_COMDAT : 0));
      |                    ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
```




More information about the All-commits mailing list