[PATCH] D16310: new clang-tidy checker misc-long-cast

Daniel Marjamäki via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 20 05:04:32 PST 2016


danielmarjamaki added a comment.

In http://reviews.llvm.org/D16310#330367, @LegalizeAdulthood wrote:

> Why not supply a fixit that removes the cast?


I am skeptic. There are different valid fixes.

Example code:

  l = (long)(a*1000);

Fix1:

  l = ((long)a * 1000);

Fix2:

  l = (a * (long)1000);

Fix3:

  l = (a * 1000L);


Repository:
  rL LLVM

http://reviews.llvm.org/D16310





More information about the cfe-commits mailing list