================
@@ -403,4 +405,35 @@ TEST_F(EnvironmentTest,
Contains(Member));
}
+TEST_F(EnvironmentTest, Stmt) {
+ using namespace ast_matchers;
+
+ std::string Code = R"cc(
+ struct S {int i;};
+ void foo() {
+ S AnS = S{1};
+ }
----------------
martinboehme wrote:
Having looked at this again, I now realize that you're analyzing the `DeclStmt`
itself, and not just the declaration's initializer. I think analyzing just the
initializer would have the same effect for the purposes of this test -- but
either of these two options seems fine, so feel free to leave this as is.
https://github.com/llvm/llvm-project/pull/91616
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits