brintos

brintos / llvm-project-archived public Read only

0
0
Text · 633 B · 6a84393 Raw
34 lines · plain
1// RUN: rm -rf %t2// RUN: mkdir -p %t3// RUN: split-file %s %t4//5// RUN: %clang_cc1 -std=c++20 %t/a.cppm -emit-module-interface -o %t/a.pcm6// RUN: %clang_cc1 -std=c++20 %t/b.cppm -emit-module-interface -o %t/b.pcm \7// RUN:   -fprebuilt-module-path=%t8// RUN: %clang_cc1 -std=c++20 %t/test.cc -fsyntax-only -verify \9// RUN:   -fprebuilt-module-path=%t10 11//--- foo.h12inline auto x = []{};13 14//--- a.cppm15module;16#include "foo.h"17export module a;18export using ::x;19 20//--- b.cppm21module;22import a;23#include "foo.h"24export module b;25export using ::x;26 27//--- test.cc28// expected-no-diagnostics29import a;30import b;31void test() {32  x();33}34