[PATCH] D96542: [clang-tidy] Fix `TransformerClangTidyCheck`'s handling of include insertions.

Haojian Wu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 12 04:17:11 PST 2021


hokein accepted this revision.
hokein added a comment.
This revision is now accepted and ready to land.

Thanks, the fix looks good.

> This patch was tested manually. The clang tidy unit test framework does not
> support testing changes to header files. Given that this is a bug fix for a live
> bug, the patch relies on manual testing rather than blocking on upgrading the
> unit test framework.

If extending the test framework is too much work, I think we can write a lit test for a transformer-based check e.g. abseil-string-find-str-contains: setup an include header, and verify the include is inserted in the header.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D96542/new/

https://reviews.llvm.org/D96542



More information about the cfe-commits mailing list