diff options
| -rw-r--r-- | lld/ELF/Symbols.cpp | 16 | ||||
| -rw-r--r-- | lld/ELF/Symbols.h | 2 |
2 files changed, 4 insertions, 14 deletions
diff --git a/lld/ELF/Symbols.cpp b/lld/ELF/Symbols.cpp index 798e8c6d17a..2f7749ffc65 100644 --- a/lld/ELF/Symbols.cpp +++ b/lld/ELF/Symbols.cpp @@ -92,20 +92,12 @@ static typename ELFT::uint getSymVA(const SymbolBody &Body, SymbolBody::SymbolBody(Kind K, uint32_t NameOffset, uint8_t StOther, uint8_t Type) - : SymbolKind(K), IsLocal(true), Type(Type), StOther(StOther), - NameOffset(NameOffset) { - init(); -} + : SymbolKind(K), NeedsCopyOrPltAddr(false), IsLocal(true), Type(Type), + StOther(StOther), NameOffset(NameOffset) {} SymbolBody::SymbolBody(Kind K, StringRef Name, uint8_t StOther, uint8_t Type) - : SymbolKind(K), IsLocal(false), Type(Type), StOther(StOther), - Name({Name.data(), Name.size()}) { - init(); -} - -void SymbolBody::init() { - NeedsCopyOrPltAddr = false; -} + : SymbolKind(K), NeedsCopyOrPltAddr(false), IsLocal(false), Type(Type), + StOther(StOther), Name({Name.data(), Name.size()}) {} // Returns true if a symbol can be replaced at load-time by a symbol // with the same name defined in other ELF executable or DSO. diff --git a/lld/ELF/Symbols.h b/lld/ELF/Symbols.h index 78b14a71bc1..e719d574e23 100644 --- a/lld/ELF/Symbols.h +++ b/lld/ELF/Symbols.h @@ -43,8 +43,6 @@ struct Symbol; // The base class for real symbol classes. class SymbolBody { - void init(); - public: enum Kind { DefinedFirst, |

