[clang-tools-extra] r370343 - Fix MSVC "not all control paths return a value" warning. NFCI.

Simon Pilgrim via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 29 05:37:03 PDT 2019


Author: rksimon
Date: Thu Aug 29 05:37:02 2019
New Revision: 370343

URL: http://llvm.org/viewvc/llvm-project?rev=370343&view=rev
Log:
Fix MSVC "not all control paths return a value" warning. NFCI.

Modified:
    clang-tools-extra/trunk/clangd/refactor/tweaks/ExtractFunction.cpp

Modified: clang-tools-extra/trunk/clangd/refactor/tweaks/ExtractFunction.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/refactor/tweaks/ExtractFunction.cpp?rev=370343&r1=370342&r2=370343&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/refactor/tweaks/ExtractFunction.cpp (original)
+++ clang-tools-extra/trunk/clangd/refactor/tweaks/ExtractFunction.cpp Thu Aug 29 05:37:02 2019
@@ -132,6 +132,7 @@ const Node *getParentOfRootStmts(const N
     // always unselected.
     return Parent->ASTNode.get<DeclStmt>() ? Parent->Parent : Parent;
   }
+  llvm_unreachable("Unhandled SelectionTree::Selection enum");
 }
 
 // The ExtractionZone class forms a view of the code wrt Zone.




More information about the cfe-commits mailing list