Is your feature request related to a problem? Please describe.
I see when using linter there are lot of. improvements that can be done. on the front of some neat practices when coming to the C++ codebase. Such fixes are automatically flagged by clang with correct tagging and explanation. One fix this when the linter is set up on the system and it is enabled to flag that error/warning.
Describe the solution you'd like
This should be part of the lint setup, gradually can be enabled. So that clang-tidy fixes can be applied automatically by the developer at the time of PR creation.
Describe alternatives you've considered
Open to suggestions.
I'd be okay with that but... Previous attempts at using clang-tidy / clang-format stranded on:
Churn - it's hard to apply them incrementally. Landing a big fix-up commit causes conflicts with most open PRs.
Versions - different versions of those tools behave differently (although clang-format at least seems to have stabilized somewhat)
Agree with you @bnoordhuis on the point 1, but how can we plan to have a gradual inclusion of a tool in. the project because according to me it makes sense to include this in the projects as the underlying tools which we use like v8 also have this config and are getting benefited from this. I might not have that much context of the internals but according to me, it seems a valid bet to at least kickstart a discussion or slowly move the existing code towards it. Maybe we can work on top of v8 config.
For the record, I don't disagree. :-)
clang-format has a sort-of-incremental mode where you can apply it to diffs (clang-format-diff, also available as a git extension.)
I proposed introducing it at one time but, IIRC, that stranded on the versions issue I mentioned. Maybe we can reevaluate that again.
There's a similar thing for clang-tidy (unsurprisingly called clang-tidy-diff) but I've never tried it so I can't vouch for it.
clang-format has a sort-of-incremental mode where you can apply it to diffs (clang-format-diff, also available as a git extension.)
I think that's what we use when you run make format-cpp
Most helpful comment
I think that's what we use when you run
make format-cpp