[PATCH] D90180: [clang-tidy] find/fix unneeded semicolon after switch

Tom Rix via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sat Oct 31 05:59:19 PDT 2020


trixirt marked 2 inline comments as done.
trixirt added a comment.

I am trying to address problems treewide so around 100 changes per fix.
Doing that requires consensus that the fix is generally ok for every subsystem in the code base.
So while clang will fix
switch () {} ; 
it will also fix
for () {

  // tbd : add something here
  ;

}
consensus needs to be found on as narrow a fix as possible.
so there will be a specialized fixer for each problem consensus is reached on.

As for leaving whitespace fixing as an exercise for the user.
No change will be accepted with a whitespace problem.
When there are 100 fixes, there are 100 files to open, find the line, fix the line.
This is slow and error prone.

Another slow part is manually commit and submitting the fixes and doing a review cycle.
But if your fixer can automagically do everything you can  hook it into a c/i and and
it will keep the codebase free of its set of fixers while we all do something more 
interesting.

i am working on the kernel build to do this now.
It would be helpful if this and future fixers could live in clang-tidy's linuxkernel/
which is already part of the kernel build so i don't have to reinvent how to find them.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D90180



More information about the cfe-commits mailing list