Skip to content

Commit

Permalink
Fix -Wcovered-switch-default warnings from r314821
Browse files Browse the repository at this point in the history
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@314826 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
zmodem committed Oct 3, 2017
1 parent f8a9b39 commit f6bdff9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions lib/DebugInfo/PDB/PDBExtras.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,11 @@ raw_ostream &llvm::pdb::operator<<(raw_ostream &OS, const PDB_DataKind &Data) {
raw_ostream &llvm::pdb::operator<<(raw_ostream &OS,
const codeview::RegisterId &Reg) {
switch (Reg) {
#define CV_REGISTER(name, val) case codeview::RegisterId::name: OS << #name; break;
#define CV_REGISTER(name, val) case codeview::RegisterId::name: OS << #name; return OS;
#include "llvm/DebugInfo/CodeView/CodeViewRegisters.def"
#undef CV_REGISTER
default:
OS << static_cast<int>(Reg);
}
OS << static_cast<int>(Reg);
return OS;
}

Expand Down
3 changes: 1 addition & 2 deletions tools/llvm-pdbutil/MinimalSymbolDumper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -290,9 +290,8 @@ static std::string formatRegisterId(RegisterId Id) {
#define CV_REGISTER(name, val) RETURN_CASE(RegisterId, name, #name)
#include "llvm/DebugInfo/CodeView/CodeViewRegisters.def"
#undef CV_REGISTER
default:
return formatUnknownEnum(Id);
}
return formatUnknownEnum(Id);
}

static std::string formatRange(LocalVariableAddrRange Range) {
Expand Down

0 comments on commit f6bdff9

Please sign in to comment.