Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / CXX / module / module.private.frag / p1.cpp
blobaf3d52f3bd325b1fef3f1b412164bccfcafb59c5
1 // RUN: rm -rf %t
2 // RUN: mkdir %t
3 // RUN: split-file %s %t
5 // RUN: %clang_cc1 -std=c++20 -emit-module-interface %t/parta.cppm -o %t/mod-parta.pcm -fsyntax-only -verify
6 // RUN: %clang_cc1 -std=c++20 -emit-module-interface %t/impl.cppm -o %t/mod-impl.pcm -fsyntax-only -verify
7 // RUN: %clang_cc1 -std=c++20 -emit-module-interface %t/primary.cppm -o %t/mod.pcm -fsyntax-only -verify
9 //--- parta.cppm
10 export module mod:parta;
12 module :private; // expected-error {{private module fragment declaration with no preceding module declaration}}
14 //--- impl.cppm
16 module mod:impl;
18 module :private; // expected-error {{private module fragment declaration with no preceding module declaration}}
20 //--- primary.cppm
21 //expected-no-diagnostics
22 export module mod;
24 module :private;