brintos

brintos / llvm-project-archived public Read only

0
0
Text · 714 B · c5fff64 Raw
33 lines · plain
1// RUN:     %clang_cc1 -std=c++20 -emit-module-interface %s -o %t.pcm -verify2// RUN:     %clang_cc1 -std=c++20 -emit-module-interface %s -o %t.pcm -verify -DERRORS3 4export module foo;5#ifndef ERRORS6// expected-no-diagnostics7#else8// FIXME: diagnose missing module-declaration when building module interface9 10// FIXME: proclaimed-ownership-declarations?11 12export {13  int a;14  int b;15}16export int c;17 18namespace N {19export void f() {}20} // namespace N21 22export struct T {23} t;24 25struct S {26  export int n;        // expected-error {{expected member name or ';'}}27  export static int n; // expected-error {{expected member name or ';'}}28};29void f() {30  export int n; // expected-error {{expected expression}}31}32#endif33