[llvm] r308889 - Format some case labels and shrink an anonymous namespace NFC
Reid Kleckner via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 24 09:16:17 PDT 2017
Author: rnk
Date: Mon Jul 24 09:16:17 2017
New Revision: 308889
URL: http://llvm.org/viewvc/llvm-project?rev=308889&view=rev
Log:
Format some case labels and shrink an anonymous namespace NFC
Modified:
llvm/trunk/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp?rev=308889&r1=308888&r2=308889&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp (original)
+++ llvm/trunk/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp Mon Jul 24 09:16:17 2017
@@ -545,8 +545,6 @@ void CodeViewDebug::emitTypeInformation(
}
}
-namespace {
-
static SourceLanguage MapDWLangToCVLang(unsigned DWLang) {
switch (DWLang) {
case dwarf::DW_LANG_C:
@@ -580,9 +578,11 @@ static SourceLanguage MapDWLangToCVLang(
}
}
+namespace {
struct Version {
int Part[4];
};
+} // end anonymous namespace
// Takes a StringRef like "clang 4.0.0.0 (other nonsense 123)" and parses out
// the version number.
@@ -605,22 +605,19 @@ static Version parseVersion(StringRef Na
static CPUType mapArchToCVCPUType(Triple::ArchType Type) {
switch (Type) {
- case Triple::ArchType::x86:
- return CPUType::Pentium3;
- case Triple::ArchType::x86_64:
- return CPUType::X64;
- case Triple::ArchType::thumb:
- return CPUType::Thumb;
- case Triple::ArchType::aarch64:
- return CPUType::ARM64;
- default:
- report_fatal_error("target architecture doesn't map to a CodeView "
- "CPUType");
+ case Triple::ArchType::x86:
+ return CPUType::Pentium3;
+ case Triple::ArchType::x86_64:
+ return CPUType::X64;
+ case Triple::ArchType::thumb:
+ return CPUType::Thumb;
+ case Triple::ArchType::aarch64:
+ return CPUType::ARM64;
+ default:
+ report_fatal_error("target architecture doesn't map to a CodeView CPUType");
}
}
-} // end anonymous namespace
-
void CodeViewDebug::emitCompilerInformation() {
MCContext &Context = MMI->getContext();
MCSymbol *CompilerBegin = Context.createTempSymbol(),
More information about the llvm-commits
mailing list