[PATCH] D141058: [clang-tidy] fix wrong fixup for bugprone-implicit-widening-of-multiplication-result

Vincent LE GARREC via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 10 05:11:57 PST 2023


bansan added a comment.

About my template example: I wanted to say that the actual `bugprone-implicit-widening-of-multiplication-result` rule looks to not analyze template calculation problem. So I think it's better to use the desugared type (`size_t`).

It's not acceptable (IMHO) that the hard-coded `size_t` is resolved as `long`. According to https://en.cppreference.com/w/cpp/language/types `long` may be 32 bits.

Unfortunately, I don't know anything about AST and which function you should use :/


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D141058



More information about the cfe-commits mailing list