Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / compiler-rt / test / ubsan_minimal / TestCases / implicit-integer-sign-change.c
blob0f1bbbf2e21460e04c20c7631348404342e6168d
1 // RUN: %clang -fsanitize=implicit-integer-sign-change %s -o %t && %run %t 2>&1 | FileCheck %s --check-prefixes=CHECK
3 #include <stdint.h>
5 int main() {
6 // CHECK-NOT: implicit-conversion
8 // Explicitly casting hides it,
9 int32_t n0 = (int32_t)(~((uint32_t)0));
11 // Positive tests.
12 int32_t t0 = (~((uint32_t)0));
13 // CHECK: implicit-conversion by 0x{{[[:xdigit:]]+$}}
14 // CHECK-NOT: implicit-conversion
16 return 0;