[clang] Implement lifetime analysis for lifetime_capture_by(X) (#115921)
[llvm-project.git] / clang / test / Modules / cxx20-export-import.cpp
blob0b505668e8589177075c825b758196885e0997e8
2 // RUN: rm -rf %t
3 // RUN: mkdir -p %t
4 // RUN: split-file %s %t
5 //
6 // RUN: %clang_cc1 -std=c++20 %t/dummy.cppm -emit-module-interface -o %t/dummy.pcm
7 // RUN: %clang_cc1 -std=c++20 -fprebuilt-module-path=%t -verify %t/test.cpp
10 //--- dummy.cppm
11 export module dummy;
13 //--- test.cpp
14 export import dummy; // expected-error {{export declaration can only be used within a module purview}}