Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / Analysis / inline-not-supported.c
blobb0382dc35ef47d6437a964d1061b384431fb025b
1 // RUN: %clang_analyze_cc1 -fblocks -analyzer-checker=core -verify %s
3 // For now, don't inline varargs.
4 void foo(int *x, ...) {
5 *x = 1;
8 void bar(void) {
9 foo(0, 2); // no-warning
12 // For now, don't inline vararg blocks.
13 void (^baz)(int *x, ...) = ^(int *x, ...) { *x = 1; };
15 void taz(void) {
16 baz(0, 2); // no-warning
19 // For now, don't inline global blocks.
20 void (^qux)(int *p) = ^(int *p) { *p = 1; };
21 void test_qux(void) {
22 qux(0); // no-warning
26 void test_analyzer_is_running(void) {
27 int *p = 0;
28 *p = 0xDEADBEEF; // expected-warning {{null}}