diff options
| author | Rafael Espindola <rafael.espindola@gmail.com> | 2017-07-05 22:15:58 +0000 |
|---|---|---|
| committer | Rafael Espindola <rafael.espindola@gmail.com> | 2017-07-05 22:15:58 +0000 |
| commit | 7016a1470246c3570edc65751ff471b7a5fea718 (patch) | |
| tree | 1e667fd210211debc2eb31e3f7bb7b31f238e031 | |
| parent | ad7137838e6d78f8f2f86041bd3047a7495e8295 (diff) | |
| download | bcm5719-llvm-7016a1470246c3570edc65751ff471b7a5fea718.tar.gz bcm5719-llvm-7016a1470246c3570edc65751ff471b7a5fea718.zip | |
Using existing variable. NFC.
llvm-svn: 307211
| -rw-r--r-- | lld/ELF/Relocations.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/lld/ELF/Relocations.cpp b/lld/ELF/Relocations.cpp index 9c8ef243bc7..52dbe4b583d 100644 --- a/lld/ELF/Relocations.cpp +++ b/lld/ELF/Relocations.cpp @@ -1073,13 +1073,12 @@ void ThunkCreator::forEachExecInputSection( OutputSection *OS = Cmd->Sec; if (!(OS->Flags & SHF_ALLOC) || !(OS->Flags & SHF_EXECINSTR)) continue; - if (OutputSectionCommand *C = Script->getCmd(OS)) - for (BaseCommand *BC : C->Commands) - if (auto *ISD = dyn_cast<InputSectionDescription>(BC)) { - CurTS = nullptr; - for (InputSection* IS : ISD->Sections) - Fn(OS, &ISD->Sections, IS); - } + for (BaseCommand *BC : Cmd->Commands) + if (auto *ISD = dyn_cast<InputSectionDescription>(BC)) { + CurTS = nullptr; + for (InputSection *IS : ISD->Sections) + Fn(OS, &ISD->Sections, IS); + } } } |

