[PATCH] D31308: [clang-tidy] new check readability-no-alternative-tokens

Gonzalo BG via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Mar 24 12:11:31 PDT 2017


gnzlbg added a comment.

Thanks for working on this!

> I'm not sure if it would be helpful to have this check in both ways. I did a code search for "not_eq", "bitand" and "and_eq" on github, and their usage seems to be a clear minority.

I actually was requesting the opposite version of this (but suggesting to implement both), because for me "if (!something)" is much harder to read than "if (not something)" (I am a bit blind).

> So I would propose to keep the features as-is for now, change the name to readability-operators-representation, and then later (someone else?) might also add an option for making this work the other way around. Would that be ok for you?

Sounds good to me. This solves half of the problem, and I agree with you that more people will benefit from this check than from the opposite check. Thanks again for working on this!


Repository:
  rL LLVM

https://reviews.llvm.org/D31308





More information about the cfe-commits mailing list