Endre =?utf-8?q?F=C3=BCl=C3=B6p?= <endre.fu...@sigmatechnology.com>, Endre =?utf-8?q?F=C3=BCl=C3=B6p?= <endre.fu...@sigmatechnology.com>, Endre =?utf-8?q?F=C3=BCl=C3=B6p?= <endre.fu...@sigmatechnology.com> Message-ID: In-Reply-To: <llvm.org/llvm/llvm-project/pull/152...@github.com>
================ @@ -152,4 +152,23 @@ TEST(ExprEngineVisitTest, checkLocationAndBind) { EXPECT_TRUE(LocPos > BindPos); } +TEST(ExprEngineVisitTest, checkLocationAndBindInitialization) { + std::string Diags; + EXPECT_TRUE(runCheckerOnCode<addMemAccessChecker>(R"( + class MyClass{ + public: + int Value; + }; + extern MyClass MyClassRead; + void top() { + MyClass MyClassWrite = MyClassRead; + } ---------------- steakhal wrote: ```suggestion void top(MyClass param) { MyClass MyClassWrite = param; } ``` https://github.com/llvm/llvm-project/pull/152137 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits