]> granicus.if.org Git - llvm/commitdiff
[MC] Clean up unused inline function and non-anchor defaulted destructors; NFCI
authorHubert Tong <hubert.reinterpretcast@gmail.com>
Sat, 9 Feb 2019 02:11:51 +0000 (02:11 +0000)
committerHubert Tong <hubert.reinterpretcast@gmail.com>
Sat, 9 Feb 2019 02:11:51 +0000 (02:11 +0000)
Summary:
Take care of some missing clean-ups that belong with r249548 and some
other copy/paste that had happened. In particular, the destructors are
no longer vtable anchors after r249548; and `setSectionName` in
`MCSectionWasm` is private and unused since r313058 culled its only
caller. The destructors are now implicitly defined, and the unused
function is removed.

Reviewers: nemanjai, jasonliu, grosbach

Reviewed By: nemanjai

Subscribers: sbc100, aheejin, sunfish, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D57182

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@353597 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/MC/MCSectionCOFF.h
include/llvm/MC/MCSectionELF.h
include/llvm/MC/MCSectionWasm.h
lib/MC/MCSectionCOFF.cpp
lib/MC/MCSectionELF.cpp
lib/MC/MCSectionWasm.cpp

index 68618f1960c2dc752ba4e68f170aec93b2dfd3ea..8be95e0f1de5dd8e16ad5260d65d54444ab9b22d 100644 (file)
@@ -62,8 +62,6 @@ private:
   }
 
 public:
-  ~MCSectionCOFF();
-
   /// Decides whether a '.section' directive should be printed before the
   /// section name
   bool ShouldOmitSectionDirective(StringRef Name, const MCAsmInfo &MAI) const;
index f61cd03bd42c2a6d800938fb57b26d6600f0837f..fe6b2d7afc79411a6065a78fc81c8de915e8cef0 100644 (file)
@@ -63,8 +63,6 @@ private:
   void setSectionName(StringRef Name) { SectionName = Name; }
 
 public:
-  ~MCSectionELF();
-
   /// Decides whether a '.section' directive should be printed before the
   /// section name
   bool ShouldOmitSectionDirective(StringRef Name, const MCAsmInfo &MAI) const;
index 15f618a52358561704fc38107ab635bcb6bcd2df..0e576b7ba404fdf957671f3d84bdf159ce057443 100644 (file)
@@ -48,11 +48,7 @@ class MCSectionWasm final : public MCSection {
       : MCSection(SV_Wasm, K, Begin), SectionName(Section), UniqueID(UniqueID),
         Group(group) {}
 
-  void setSectionName(StringRef Name) { SectionName = Name; }
-
 public:
-  ~MCSectionWasm();
-
   /// Decides whether a '.section' directive should be printed before the
   /// section name
   bool shouldOmitSectionDirective(StringRef Name, const MCAsmInfo &MAI) const;
index 8fd4c64d0d9956ff00642822dbda27962e3bb419..f0c06f70bd734693731079426931069334af28e8 100644 (file)
@@ -14,8 +14,6 @@
 
 using namespace llvm;
 
-MCSectionCOFF::~MCSectionCOFF() = default; // anchor.
-
 // ShouldOmitSectionDirective - Decides whether a '.section' directive
 // should be printed before the section name
 bool MCSectionCOFF::ShouldOmitSectionDirective(StringRef Name,
index dd883665e0b334502b5ca9f6d571a6dbc2e574e4..e3c24efa93f31f864565f9d75a9f9e9f5384876c 100644 (file)
@@ -17,8 +17,6 @@
 
 using namespace llvm;
 
-MCSectionELF::~MCSectionELF() = default; // anchor.
-
 // Decides whether a '.section' directive
 // should be printed before the section name.
 bool MCSectionELF::ShouldOmitSectionDirective(StringRef Name,
index a8f56897ee13522334f17ba929fc5b044fdda000..164ded9a1f8877c7b347443a6b120671d3e03088 100644 (file)
@@ -14,8 +14,6 @@
 
 using namespace llvm;
 
-MCSectionWasm::~MCSectionWasm() = default; // anchor.
-
 // Decides whether a '.section' directive
 // should be printed before the section name.
 bool MCSectionWasm::shouldOmitSectionDirective(StringRef Name,