[PATCH] D71607: [clang-tidy] Add unsigned subtraction warning, with suggestion to convert to unsigned literals.

Jonas Toth via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 18 03:08:01 PST 2019


JonasToth added a comment.

Somewhat related: https://reviews.llvm.org/D40854
This is a check that tried to enforce not mixing any signed/unsigned arithmetic. there was no feedback from the cppcoreguideline-ppl on how to proceed with edge cases and occassion where mixing is not avoidable (e.g. `unsigned short + unsigned short + unsigned short`, because of integer promotion).
Just to inform you as it might help with testing or anything like that.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D71607





More information about the cfe-commits mailing list