brintos

brintos / llvm-project-archived public Read only

0
0
Text · 498 B · 334af84 Raw
27 lines · plain
1// RUN: rm -rf %t2// RUN: mkdir -p %t3// RUN: split-file %s %t4//5// RUN: %clang -std=c++20 %t/a.cppm --precompile -o %t/a.pcm6// RUN: %clang -std=c++20 %t/test.cc -fprebuilt-module-path=%t -fsyntax-only -Xclang -verify7 8//--- a.h9namespace ns {10namespace {11template <typename G> void func() {}12}13template <typename T = long> void a() { func<T>(); }14}15 16//--- a.cppm17module;18#include "a.h"19export module a;20export using ns::a;21 22//--- test.cc23import a;24auto m = (a(), 0);25 26// expected-no-diagnostics27