forked from OSchip/llvm-project
Remove redundant empty destructors.
Both File and Atom have virtual destructors. We don't need to repeat that in derived classes. llvm-svn: 231568
This commit is contained in:
parent
6b329f5cd2
commit
51ae7e8622
|
@ -36,7 +36,6 @@ public:
|
|||
|
||||
protected:
|
||||
AbsoluteAtom() : Atom(definitionAbsolute) {}
|
||||
virtual ~AbsoluteAtom() {}
|
||||
};
|
||||
|
||||
} // namespace lld
|
||||
|
|
|
@ -50,8 +50,6 @@ public:
|
|||
return std::set<StringRef>();
|
||||
}
|
||||
|
||||
virtual ~ArchiveLibraryFile() {}
|
||||
|
||||
protected:
|
||||
/// only subclasses of ArchiveLibraryFile can be instantiated
|
||||
ArchiveLibraryFile(StringRef path) : File(path, kindArchiveLibrary) {}
|
||||
|
|
|
@ -365,12 +365,6 @@ protected:
|
|||
// constructor.
|
||||
DefinedAtom() : Atom(definitionRegular) { }
|
||||
|
||||
// The memory for DefinedAtom objects is always managed by the owning File
|
||||
// object. Therefore, no one but the owning File object should call delete on
|
||||
// an Atom. In fact, some File objects may bulk allocate an array of Atoms,
|
||||
// so they cannot be individually deleted by anyone.
|
||||
virtual ~DefinedAtom() {}
|
||||
|
||||
/// \brief Returns a pointer to the Reference object that the abstract
|
||||
/// iterator "points" to.
|
||||
virtual const Reference *derefIterator(const void *iter) const = 0;
|
||||
|
|
|
@ -46,7 +46,6 @@ public:
|
|||
|
||||
protected:
|
||||
SharedLibraryAtom() : Atom(definitionSharedLibrary) {}
|
||||
virtual ~SharedLibraryAtom() {}
|
||||
};
|
||||
|
||||
} // namespace lld
|
||||
|
|
|
@ -20,8 +20,6 @@ namespace lld {
|
|||
///
|
||||
class SharedLibraryFile : public File {
|
||||
public:
|
||||
virtual ~SharedLibraryFile() {}
|
||||
|
||||
static bool classof(const File *f) {
|
||||
return f->kind() == kindSharedLibrary;
|
||||
}
|
||||
|
|
|
@ -67,7 +67,6 @@ public:
|
|||
|
||||
protected:
|
||||
UndefinedAtom() : Atom(definitionUndefined) {}
|
||||
virtual ~UndefinedAtom() {}
|
||||
};
|
||||
|
||||
} // namespace lld
|
||||
|
|
Loading…
Reference in New Issue