[PATCH] D54757: [clang-tidy] new check: bugprone-branch-clone

Jonas Toth via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Dec 4 03:14:43 PST 2018


JonasToth added a comment.

> A quick, tangentially related idea: Would it be useful to implement multiline nolint sections (e.g. `//BEGINNOLINT` – `//ENDNOLINT` or something similar)? This would be helpful for using clang-tidy on projects that contain some automatically generated fragments.

Yes, I think so. The filtering mechanism we have right now are not sufficient i think.
Features similar to pylint would be great, were you can disable certain checks for scopes (functions, modules, classes). With this kind of functionality we could bring clang-tidy to system-level libraries too, as the "unsafe" code is usually chatty in many regards, but with fine-grained and powerful filtering it should be easier to manage the output.

TL;DR I am in favor of such approaches, a short proposal (with what you plan) on the mailing-list wouldn't hurt for more opinions :)


Repository:
  rCTE Clang Tools Extra

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

https://reviews.llvm.org/D54757





More information about the cfe-commits mailing list