From: Frederic Riss Date: Tue, 16 Sep 2014 12:58:01 +0000 (+0000) Subject: Make DWARFUnitSection final and change base class to non-virtual protected destructor. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=baaa29f3a2b5b4463921fe3af7669850e7de81fd;p=oota-llvm.git Make DWARFUnitSection final and change base class to non-virtual protected destructor. As per dblaikie suggestion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@217871 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/DebugInfo/DWARFUnit.h b/lib/DebugInfo/DWARFUnit.h index ca105be00d6..e8205be13f4 100644 --- a/lib/DebugInfo/DWARFUnit.h +++ b/lib/DebugInfo/DWARFUnit.h @@ -36,13 +36,14 @@ public: /// same section this Unit originated from. virtual DWARFUnit *getUnitForOffset(uint32_t Offset) const = 0; - virtual ~DWARFUnitSectionBase() {} +protected: + ~DWARFUnitSectionBase() {} }; /// Concrete instance of DWARFUnitSection, specialized for one Unit type. template -class DWARFUnitSection : public SmallVector, 1>, - public DWARFUnitSectionBase { +class DWARFUnitSection final : public SmallVector, 1>, + public DWARFUnitSectionBase { struct UnitOffsetComparator { bool operator()(const std::unique_ptr &LHS,