[clang] 75e90ea - Fix MSVC "not all control paths return a value" warning. NFCI.

Simon Pilgrim via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 26 02:28:11 PDT 2022


Author: Simon Pilgrim
Date: 2022-09-26T10:27:38+01:00
New Revision: 75e90ea7668fc5a7cc7fbae13070bf8558f884de

URL: https://github.com/llvm/llvm-project/commit/75e90ea7668fc5a7cc7fbae13070bf8558f884de
DIFF: https://github.com/llvm/llvm-project/commit/75e90ea7668fc5a7cc7fbae13070bf8558f884de.diff

LOG: Fix MSVC "not all control paths return a value" warning. NFCI.

Added: 
    

Modified: 
    clang/lib/CodeGen/CGDebugInfo.cpp

Removed: 
    


################################################################################
diff  --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp
index 6f6bad1052a15..63027413f37aa 100644
--- a/clang/lib/CodeGen/CGDebugInfo.cpp
+++ b/clang/lib/CodeGen/CGDebugInfo.cpp
@@ -370,6 +370,7 @@ CGDebugInfo::computeChecksum(FileID FID, SmallString<64> &Checksum) const {
     llvm::toHex(llvm::SHA256::hash(Data), /*LowerCase=*/true, Checksum);
     return llvm::DIFile::CSK_SHA256;
   }
+  llvm_unreachable("Unhandled DebugSrcHashKind enum");
 }
 
 Optional<StringRef> CGDebugInfo::getSource(const SourceManager &SM,


        


More information about the cfe-commits mailing list