[clang] Implement lifetime analysis for lifetime_capture_by(X) (#115921)
[llvm-project.git] / clang / test / ClangScanDeps / modules-disable-free.c
blob35ca8cc3c88cda6763e64275c6dd45336d9be997
1 // RUN: rm -rf %t
2 // RUN: split-file %s %t
3 // RUN: sed -e "s|DIR|%/t|g" %t/compile-commands.json.in > %t/compile-commands.json
5 // RUN: clang-scan-deps -compilation-database %t/compile-commands.json -j 1 -format experimental-full \
6 // RUN: -mode preprocess-dependency-directives > %t/output
7 // RUN: FileCheck %s < %t/output
9 // CHECK: "-disable-free",
11 //--- compile-commands.json.in
14 "directory": "DIR",
15 "command": "clang -c DIR/main.c -fmodules -fmodules-cache-path=DIR/module-cache -fimplicit-modules -fimplicit-module-maps",
16 "file": "DIR/main.c"
19 //--- module.modulemap
21 module A {
22 header "a.h"
25 //--- a.h
27 void a(void);
29 //--- main.c
31 #include "a.h"
32 void m() {
33 a();