From: Simon Pilgrim Date: Thu, 10 Aug 2017 17:20:09 +0000 (+0000) Subject: Fix 'not all control paths return' warning on windows builds. NFCI. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=92e2e47a06b528727debdf2e7a7e7707eaa1f1cc;p=llvm Fix 'not all control paths return' warning on windows builds. NFCI. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310631 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/tools/llvm-rc/ResourceScriptToken.cpp b/tools/llvm-rc/ResourceScriptToken.cpp index 557a343b435..ab46509b394 100644 --- a/tools/llvm-rc/ResourceScriptToken.cpp +++ b/tools/llvm-rc/ResourceScriptToken.cpp @@ -215,9 +215,7 @@ Error Tokenizer::consumeToken(const Kind TokenKind) { assert(false && "Cannot consume an invalid token."); } - // This silences the compilers which cannot notice that the execution - // never reaches here. - assert(false); + llvm_unreachable("Unknown RCToken::Kind"); } bool Tokenizer::willNowRead(StringRef FollowingChars) const {