- Notifications
You must be signed in to change notification settings - Fork 15.3k
Labels
clang-queryclang:frontendLanguage frontend issues, e.g. anything involving "Sema"Language frontend issues, e.g. anything involving "Sema"confirmedVerified by a second partyVerified by a second partygood first issuehttps://github.com/llvm/llvm-project/contributehttps://github.com/llvm/llvm-project/contribute
Description
hasAnyArgument() spuriously ignores a match with the program:
void foo (void *, void *); struct S { }; void f() { S s; foo(&s, &s); } and the query:
m callExpr(hasAnyArgument(hasType(asString("S *")))) 0 matches. However, the query:
m callExpr(hasArgument(0,hasType(asString("S *")))) returns the expected result:
...clang_ast_bug_2.cpp:10:2: note: "root" binds here 10 | foo(&s, &s); | ^~~~~~~~~~~ 1 match. I am using clang-query 17.0.2 built, I believe, by Mozilla.
Metadata
Metadata
Assignees
Labels
clang-queryclang:frontendLanguage frontend issues, e.g. anything involving "Sema"Language frontend issues, e.g. anything involving "Sema"confirmedVerified by a second partyVerified by a second partygood first issuehttps://github.com/llvm/llvm-project/contributehttps://github.com/llvm/llvm-project/contribute