Skip to content

Commit e6ba0a5

Browse files
committed
Fix MSVC "not all control paths return a value" warning. NFC.
Add llvm_unreachable after switch statement for CheckerRegistry::StateFromCmdLine enum
1 parent 7a96c18 commit e6ba0a5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

clang/lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ static StringRef toString(CheckerRegistry::StateFromCmdLine Kind) {
112112
case CheckerRegistry::StateFromCmdLine::State_Unspecified:
113113
return "Unspecified";
114114
}
115+
llvm_unreachable("Unhandled CheckerRegistry::StateFromCmdLine enum");
115116
}
116117

117118
LLVM_DUMP_METHOD void

0 commit comments

Comments
 (0)