[clang] [analyzer] Fix assertion failure in `CXXInstanceCall::getCXXThisVal` (PR #70837)

via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 2 09:09:55 PDT 2023


================
@@ -30,3 +30,24 @@ void test(int i) {
   clang_analyzer_dump(g4);
   // expected-warning at -1 {{&i [as 64 bit integer]}}
 }
+
+struct A {
+  int n;
+  void set(int x) {
+    n = x;
+  }
+};
+using ptr_size = decltype(sizeof(void *));
----------------
DonatNagyE wrote:

Do I see it correctly that `ptr_size` just an alias of `size_t`? If yes, then why don't you use the standard name?

https://github.com/llvm/llvm-project/pull/70837


More information about the cfe-commits mailing list