[clang] f7a38ee - [analyzer][NFC][test] Add new RUN line with support-symbolic-integer-casts=true to expr-inspection.cpp

Gabor Marton via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 15 07:07:04 PDT 2022


Author: Gabor Marton
Date: 2022-06-15T16:06:53+02:00
New Revision: f7a38eeccb03a8076e298fd6c0baed7d171f07b6

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

LOG: [analyzer][NFC][test] Add new RUN line with support-symbolic-integer-casts=true to expr-inspection.cpp

Added a new run line to bolster gradual transition of handling cast operations,
see https://discourse.llvm.org/t/roadmap-of-modeling-symbolic-cast-operations/63107

Differential Revision: https://reviews.llvm.org/D127649

Added: 
    

Modified: 
    clang/test/Analysis/expr-inspection.cpp

Removed: 
    


################################################################################
diff  --git a/clang/test/Analysis/expr-inspection.cpp b/clang/test/Analysis/expr-inspection.cpp
index 3e6530503292..94db6e38b841 100644
--- a/clang/test/Analysis/expr-inspection.cpp
+++ b/clang/test/Analysis/expr-inspection.cpp
@@ -1,9 +1,17 @@
-// RUN: %clang_analyze_cc1 -x c++ -analyzer-checker=debug.ExprInspection -verify %s
+// RUN: %clang_analyze_cc1 -x c++ -analyzer-checker=debug.ExprInspection \
+// RUN:    -analyzer-config support-symbolic-integer-casts=false \
+// RUN:    -verify %s
+
+// RUN: %clang_analyze_cc1 -x c++ -analyzer-checker=debug.ExprInspection \
+// RUN:    -analyzer-config support-symbolic-integer-casts=true \
+// RUN:    -verify %s
 
 // Self-tests for the debug.ExprInspection checker.
 
-void clang_analyzer_denote(int x, const char *str);
-void clang_analyzer_express(int x);
+template <typename T>
+void clang_analyzer_denote(T x, const char *str);
+template <typename T>
+void clang_analyzer_express(T x);
 
 // Invalid declarations to test basic correctness checks.
 void clang_analyzer_denote();


        


More information about the cfe-commits mailing list