2 // RUN: split-file %s %t
4 // RUN: %clang_cc1 -std=c++20 -triple %itanium_abi_triple \
5 // RUN: %t/a.cppm -emit-module-interface -o %t/a.pcm
7 // RUN: echo "inline int bar = 46;" >> %t/foo.h
8 // RUNX: %clang_cc1 -std=c++20 -triple %itanium_abi_triple \
9 // RUNX: %t/use.cpp -fmodule-file=a=%t/a.pcm -verify -fsyntax-only
10 // RUNX: %clang_cc1 -std=c++20 -triple %itanium_abi_triple \
11 // RUNX: %t/a.pcm -emit-llvm -o - | FileCheck %t/a.ll
13 // RUN: echo "export int var = 43;" >> %t/a.cppm
14 // RUNX: %clang_cc1 -std=c++20 -triple %itanium_abi_triple \
15 // RUNX: %t/use.cpp -fmodule-file=a=%t/a.pcm -verify -fsyntax-only
16 // RUNX: %clang_cc1 -std=c++20 -triple %itanium_abi_triple \
17 // RUNX: %t/a.pcm -emit-llvm -o - | FileCheck %t/a.ll
19 // RUN: not %clang_cc1 -std=c++20 -triple %itanium_abi_triple \
20 // RUN: -fforce-check-cxx20-modules-input-files %t/a.pcm \
21 // RUN: -emit-llvm -o - 2>&1 | FileCheck %t/a.cppm -check-prefix=CHECK-FAILURE
27 // expected-no-diagnostics
33 // CHECK-FAILURE: fatal error:{{.*}}a.cppm' has been modified since the AST file {{.*}}was built