[ELF] - Remove unnecessary template #4. NFC.
OutputSectionFactory has no ELFT templates anymore.
llvm-svn: 297720
diff --git a/lld/ELF/LinkerScript.cpp b/lld/ELF/LinkerScript.cpp
index 85312fb..4ee9e1b 100644
--- a/lld/ELF/LinkerScript.cpp
+++ b/lld/ELF/LinkerScript.cpp
@@ -375,7 +375,7 @@
// Add input sections to an output section.
for (InputSectionBase *S : V)
- Factory.addInputSec<ELFT>(S, Cmd->Name);
+ Factory.addInputSec(S, Cmd->Name);
}
}
CurOutSec = nullptr;
@@ -386,7 +386,7 @@
void LinkerScript<ELFT>::addOrphanSections(OutputSectionFactory &Factory) {
for (InputSectionBase *S : InputSections)
if (S->Live && !S->OutSec)
- Factory.addInputSec<ELFT>(S, getOutputSectionName(S->Name));
+ Factory.addInputSec(S, getOutputSectionName(S->Name));
}
template <class ELFT> static bool isTbss(OutputSection *Sec) {
diff --git a/lld/ELF/OutputSections.cpp b/lld/ELF/OutputSections.cpp
index d095faf..9b7eda1 100644
--- a/lld/ELF/OutputSections.cpp
+++ b/lld/ELF/OutputSections.cpp
@@ -334,7 +334,6 @@
IS->File->getName());
}
-template <class ELFT>
void OutputSectionFactory::addInputSec(InputSectionBase *IS,
StringRef OutsecName) {
if (!IS->Live) {
@@ -414,13 +413,5 @@
template void OutputSection::writeTo<ELF64LE>(uint8_t *Buf);
template void OutputSection::writeTo<ELF64BE>(uint8_t *Buf);
-template void OutputSectionFactory::addInputSec<ELF32LE>(InputSectionBase *,
- StringRef);
-template void OutputSectionFactory::addInputSec<ELF32BE>(InputSectionBase *,
- StringRef);
-template void OutputSectionFactory::addInputSec<ELF64LE>(InputSectionBase *,
- StringRef);
-template void OutputSectionFactory::addInputSec<ELF64BE>(InputSectionBase *,
- StringRef);
}
}
diff --git a/lld/ELF/OutputSections.h b/lld/ELF/OutputSections.h
index 72d3ccf..01ffc95 100644
--- a/lld/ELF/OutputSections.h
+++ b/lld/ELF/OutputSections.h
@@ -136,7 +136,6 @@
OutputSectionFactory(std::vector<OutputSection *> &OutputSections);
~OutputSectionFactory();
- template <class ELFT>
void addInputSec(InputSectionBase *IS, StringRef OutsecName);
private:
diff --git a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp
index c3f68ab..c4795f0 100644
--- a/lld/ELF/Writer.cpp
+++ b/lld/ELF/Writer.cpp
@@ -937,7 +937,7 @@
template <class ELFT> void Writer<ELFT>::createSections() {
for (InputSectionBase *IS : InputSections)
if (IS)
- Factory.addInputSec<ELFT>(IS, getOutputSectionName(IS->Name));
+ Factory.addInputSec(IS, getOutputSectionName(IS->Name));
sortBySymbolsOrder<ELFT>(OutputSections);
sortInitFini<ELFT>(findSection(".init_array"));