[lld] r250578 - Use a reference. NFC.
Rafael Espindola via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 16 16:22:23 PDT 2015
Author: rafael
Date: Fri Oct 16 18:22:23 2015
New Revision: 250578
URL: http://llvm.org/viewvc/llvm-project?rev=250578&view=rev
Log:
Use a reference. NFC.
Modified:
lld/trunk/ELF/OutputSections.cpp
Modified: lld/trunk/ELF/OutputSections.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/OutputSections.cpp?rev=250578&r1=250577&r2=250578&view=diff
==============================================================================
--- lld/trunk/ELF/OutputSections.cpp (original)
+++ lld/trunk/ELF/OutputSections.cpp Fri Oct 16 18:22:23 2015
@@ -403,8 +403,8 @@ typename ELFFile<ELFT>::uintX_t lld::elf
return cast<DefinedAbsolute<ELFT>>(S).Sym.st_value;
case SymbolBody::DefinedRegularKind: {
const auto &DR = cast<DefinedRegular<ELFT>>(S);
- const InputSection<ELFT> *SC = &DR.Section;
- return SC->OutSec->getVA() + SC->OutSecOff + DR.Sym.st_value;
+ const InputSection<ELFT> &SC = DR.Section;
+ return SC.OutSec->getVA() + SC.OutSecOff + DR.Sym.st_value;
}
case SymbolBody::DefinedCommonKind:
return Out<ELFT>::Bss->getVA() + cast<DefinedCommon<ELFT>>(S).OffsetInBSS;
More information about the llvm-commits
mailing list