[AST] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC).

llvm-svn: 318813
diff --git a/clang/lib/AST/DeclarationName.cpp b/clang/lib/AST/DeclarationName.cpp
index 1f8e26d..31bae93 100644
--- a/clang/lib/AST/DeclarationName.cpp
+++ b/clang/lib/AST/DeclarationName.cpp
@@ -1,4 +1,4 @@
-//===-- DeclarationName.cpp - Declaration names implementation --*- C++ -*-===//
+//===- DeclarationName.cpp - Declaration names implementation -------------===//
 //
 //                     The LLVM Compiler Infrastructure
 //
@@ -11,20 +11,36 @@
 // classes.
 //
 //===----------------------------------------------------------------------===//
+
 #include "clang/AST/DeclarationName.h"
 #include "clang/AST/ASTContext.h"
+#include "clang/AST/Decl.h"
+#include "clang/AST/DeclBase.h"
 #include "clang/AST/DeclCXX.h"
 #include "clang/AST/DeclTemplate.h"
+#include "clang/AST/PrettyPrinter.h"
 #include "clang/AST/Type.h"
 #include "clang/AST/TypeLoc.h"
 #include "clang/AST/TypeOrdering.h"
 #include "clang/Basic/IdentifierTable.h"
+#include "clang/Basic/LLVM.h"
+#include "clang/Basic/LangOptions.h"
+#include "clang/Basic/OperatorKinds.h"
+#include "clang/Basic/SourceLocation.h"
 #include "llvm/ADT/FoldingSet.h"
+#include "llvm/Support/Casting.h"
+#include "llvm/Support/Compiler.h"
 #include "llvm/Support/ErrorHandling.h"
 #include "llvm/Support/raw_ostream.h"
+#include <algorithm>
+#include <cassert>
+#include <cstdint>
+#include <string>
+
 using namespace clang;
 
 namespace clang {
+
 /// CXXSpecialName - Records the type associated with one of the
 /// "special" kinds of declaration names in C++, e.g., constructors,
 /// destructors, and conversion functions.
@@ -89,6 +105,8 @@
   }
 };
 
+} // namespace clang
+
 static int compareInt(unsigned A, unsigned B) {
   return (A < B ? -1 : (A > B ? 1 : 0));
 }
@@ -197,10 +215,9 @@
   case DeclarationName::CXXConstructorName:
     return printCXXConstructorDestructorName(N.getCXXNameType(), OS, Policy);
 
-  case DeclarationName::CXXDestructorName: {
+  case DeclarationName::CXXDestructorName:
     OS << '~';
     return printCXXConstructorDestructorName(N.getCXXNameType(), OS, Policy);
-  }
 
   case DeclarationName::CXXDeductionGuideName:
     OS << "<deduction guide for ";
@@ -250,13 +267,15 @@
   llvm_unreachable("Unexpected declaration name kind");
 }
 
+namespace clang {
+
 raw_ostream &operator<<(raw_ostream &OS, DeclarationName N) {
   LangOptions LO;
   N.print(OS, PrintingPolicy(LO));
   return OS;
 }
 
-} // end namespace clang
+} // namespace clang
 
 DeclarationName::NameKind DeclarationName::getNameKind() const {
   switch (getStoredNameKind()) {