bolt/deps/llvm-18.1.8/clang/test/Analysis/svalbuilder-simplify-no-crash.c
2025-02-14 19:21:04 +01:00

15 lines
346 B
C

// RUN: %clang_analyze_cc1 %s \
// RUN: -analyzer-checker=core \
// RUN: -analyzer-checker=debug.ExprInspection \
// RUN: -verify
// Here, we test that svalbuilder simplification does not produce any
// assertion failure.
// expected-no-diagnostics
void crashing(long a, _Bool b) {
(void)(a & 1 && 0);
b = a & 1;
(void)(b << 1);
}