[clang] 407afbf - [clang][examples] Remove unused variable 'key' in LLVMPrintFunctionNames.cpp (NFC)

Jie Fu via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 6 21:10:02 PST 2023


Author: Jie Fu
Date: 2023-11-07T13:09:20+08:00
New Revision: 407afbf1bc276fb70569da335e5ef57b7cb119db

URL: https://github.com/llvm/llvm-project/commit/407afbf1bc276fb70569da335e5ef57b7cb119db
DIFF: https://github.com/llvm/llvm-project/commit/407afbf1bc276fb70569da335e5ef57b7cb119db.diff

LOG: [clang][examples] Remove unused variable 'key' in LLVMPrintFunctionNames.cpp (NFC)

/llvm-project/clang/examples/LLVMPrintFunctionNames/LLVMPrintFunctionNames.cpp:33:28: error: unused variable 'key' [-Werror,-Wunused-variable]
  static llvm::AnalysisKey key;
                           ^
1 error generated.

Added: 
    

Modified: 
    clang/examples/LLVMPrintFunctionNames/LLVMPrintFunctionNames.cpp

Removed: 
    


################################################################################
diff  --git a/clang/examples/LLVMPrintFunctionNames/LLVMPrintFunctionNames.cpp b/clang/examples/LLVMPrintFunctionNames/LLVMPrintFunctionNames.cpp
index 739740cecdf47d2..6cb87e4b5e19c44 100644
--- a/clang/examples/LLVMPrintFunctionNames/LLVMPrintFunctionNames.cpp
+++ b/clang/examples/LLVMPrintFunctionNames/LLVMPrintFunctionNames.cpp
@@ -29,9 +29,6 @@ namespace {
 class PrintPass final : public llvm::AnalysisInfoMixin<PrintPass> {
   friend struct llvm::AnalysisInfoMixin<PrintPass>;
 
-private:
-  static llvm::AnalysisKey key;
-
 public:
   using Result = llvm::PreservedAnalyses;
 


        


More information about the cfe-commits mailing list