11 lines · cpp
1// RUN: %clangxx_min_runtime -fsanitize=unsigned-integer-overflow %s -o %t && %run %t 2>&1 | FileCheck %s2// RUN: %clangxx_min_runtime -fsanitize=unsigned-integer-overflow -fno-sanitize-recover=all %s -o %t && not --crash %run %t 2>&1 | FileCheck %s3 4#include <stdint.h>5 6int main() {7 uint32_t k = 0x87654321;8 k += 0xedcba987;9 // CHECK: add-overflow by 0x{{[[:xdigit:]]+$}}10}11