[PATCH] D51360: [clang-tidy] Use simple string matching instead of Regex
Haojian Wu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 29 06:11:06 PDT 2018
hokein added a comment.
Thanks very much for improving it!
================
Comment at: clang-tools-extra/clang-tidy/abseil/AbseilMatcher.h:45
- llvm::Regex RE(
- "absl/(algorithm|base|container|debugging|memory|meta|numeric|strings|"
- "synchronization|time|types|utility)");
----------------
The logic is a bit subtle here. Agree that using `regex` is overkill.
We still want substring match here, since the Filename does not always start with `absl/`, so your improvement will change the behavior. I think we should do `absl/[absl-libraries]` substring match.
https://reviews.llvm.org/D51360
More information about the cfe-commits
mailing list