[PATCH] D94126: [ASTMatchers] Make it possible to use empty variadic matchers
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Jan 8 07:53:28 PST 2021
aaron.ballman added inline comments.
================
Comment at: clang/lib/ASTMatchers/ASTMatchersInternal.cpp:402
ArrayRef<DynTypedMatcher> InnerMatchers) {
+ if (InnerMatchers.empty())
+ return true;
----------------
Does it make sense to return `true` when there are no inner matchers? I would have thought that that if there are no matchers, nothing would match (so we'd return `false`)?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D94126/new/
https://reviews.llvm.org/D94126
More information about the cfe-commits
mailing list