[lld] r226984 - Return a boolean value directly, instead of returning true if true and false if false.
Rui Ueyama
ruiu at google.com
Fri Jan 23 18:57:20 PST 2015
Author: ruiu
Date: Fri Jan 23 20:57:20 2015
New Revision: 226984
URL: http://llvm.org/viewvc/llvm-project?rev=226984&view=rev
Log:
Return a boolean value directly, instead of returning true if true and false if false.
Modified:
lld/trunk/lib/ReaderWriter/ELF/ELFFile.h
Modified: lld/trunk/lib/ReaderWriter/ELF/ELFFile.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/ELFFile.h?rev=226984&r1=226983&r2=226984&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/ELFFile.h (original)
+++ lld/trunk/lib/ReaderWriter/ELF/ELFFile.h Fri Jan 23 20:57:20 2015
@@ -247,10 +247,8 @@ protected:
/// Determines if the target wants to create an atom for a section that has no
/// symbol references.
bool handleSectionWithNoSymbols(const Elf_Shdr *shdr,
- std::vector<Elf_Sym_Iter> &symbols) const {
- if (shdr && shdr->sh_type == llvm::ELF::SHT_PROGBITS && symbols.empty())
- return true;
- return false;
+ std::vector<Elf_Sym_Iter> &syms) const {
+ return shdr && (shdr->sh_type == llvm::ELF::SHT_PROGBITS) && syms.empty();
}
/// Process the Undefined symbol and create an atom for it.
More information about the llvm-commits
mailing list