From 4b6ff6b86ea04ee9a29924b7417bf6813cc05d5a Mon Sep 17 00:00:00 2001 From: Eugene Zelenko Date: Fri, 10 Feb 2017 01:33:54 +0000 Subject: [MC] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). llvm-svn: 294685 --- llvm/lib/MC/MCSectionCOFF.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'llvm/lib/MC/MCSectionCOFF.cpp') diff --git a/llvm/lib/MC/MCSectionCOFF.cpp b/llvm/lib/MC/MCSectionCOFF.cpp index 4e2df01c89c..f0709cbc251 100644 --- a/llvm/lib/MC/MCSectionCOFF.cpp +++ b/llvm/lib/MC/MCSectionCOFF.cpp @@ -8,14 +8,14 @@ //===----------------------------------------------------------------------===// #include "llvm/MC/MCSectionCOFF.h" -#include "llvm/MC/MCAsmInfo.h" -#include "llvm/MC/MCContext.h" #include "llvm/MC/MCSymbol.h" #include "llvm/Support/COFF.h" #include "llvm/Support/raw_ostream.h" +#include + using namespace llvm; -MCSectionCOFF::~MCSectionCOFF() {} // anchor. +MCSectionCOFF::~MCSectionCOFF() = default; // anchor. // ShouldOmitSectionDirective - Decides whether a '.section' directive // should be printed before the section name @@ -40,7 +40,6 @@ void MCSectionCOFF::setSelection(int Selection) const { void MCSectionCOFF::PrintSwitchToSection(const MCAsmInfo &MAI, const Triple &T, raw_ostream &OS, const MCExpr *Subsection) const { - // standard sections don't require the '.section' if (ShouldOmitSectionDirective(SectionName, MAI)) { OS << '\t' << getSectionName() << '\n'; @@ -94,7 +93,7 @@ void MCSectionCOFF::PrintSwitchToSection(const MCAsmInfo &MAI, const Triple &T, OS << "newest,"; break; default: - assert (0 && "unsupported COFF selection type"); + assert(false && "unsupported COFF selection type"); break; } assert(COMDATSymbol); -- cgit v1.2.3