[clang-tools-extra] [clang-tidy] Add new check readability-trailing-comma (PR #173669)
Baranov Victor via cfe-commits
cfe-commits at lists.llvm.org
Sun Dec 28 02:18:52 PST 2025
vbvictor wrote:
I agree that calculating lines between start/end of stmt/expr is not hard and we should do that way.
-------------------------------
The check was initially started as a reflection of a coding guide I have at work: split init-list into multiple lines if number of elements is more than N and add a trailing comma.
But depending on a number of lines instead of number of elements is indeed seems more beneficial for wider audience. I'll address all comments next week.
https://github.com/llvm/llvm-project/pull/173669
More information about the cfe-commits
mailing list