[PATCH] D52137: Added warning for unary minus used with unsigned type

Dávid Bolvanský via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sat Sep 15 15:39:33 PDT 2018


xbolva00 added a comment.

Hm, isUnsignedIntegerType seems to ignore uintN_t types?

int f(void) {

  uint8_t u8 = 1;
  uint8_t b = -u8;

}

No warning now :/


https://reviews.llvm.org/D52137





More information about the cfe-commits mailing list