[RISCV] Simplify usage of SplatPat_simm5_plus1. NFC (#125340)
[llvm-project.git] / clang / test / Analysis / undef-call.c
blob8019028282aa0b327450f98d2f94f6fe1468361e
1 // RUN: rm -rf %T/ctudir
2 // RUN: mkdir %T/ctudir
3 // RUN: %clang_cc1 -analyze -analyzer-checker=debug.ExprInspection -analyzer-config experimental-enable-naive-ctu-analysis=true -analyzer-config ctu-dir=%T/ctudir -verify %s
4 // expected-no-diagnostics
6 struct S {
7 void (*fp)(void);
8 };
10 int main(void) {
11 struct S s;
12 // This will cause the analyzer to look for a function definition that has
13 // no FunctionDecl. It used to cause a crash in AnyFunctionCall::getRuntimeDefinition.
14 // It would only occur when CTU analysis is enabled.
15 s.fp();