[clang] Implement lifetime analysis for lifetime_capture_by(X) (#115921)
[llvm-project.git] / clang / test / PCH / cxx2a-concept-specialization-expr.cpp
blob386fee2cb898434124018f798644667e4ffd21c8
1 // RUN: %clang_cc1 -std=c++2a -emit-pch %s -o %t
2 // RUN: %clang_cc1 -std=c++2a -include-pch %t -verify %s
4 // RUN: %clang_cc1 -std=c++2a -emit-pch -fpch-instantiate-templates %s -o %t
5 // RUN: %clang_cc1 -std=c++2a -include-pch %t -verify %s
7 // expected-no-diagnostics
9 #ifndef HEADER
10 #define HEADER
12 template<typename... T>
13 concept C = true;
15 namespace n {
16 template<typename... T>
17 concept C = true;
20 void f() {
21 (void)C<int>;
22 (void)C<int, void>;
23 (void)n::C<void>;
26 #else /*included pch*/
28 int main() {
29 (void)C<int>;
30 (void)C<int, void>;
31 (void)n::C<void>;
32 f();
35 #endif // HEADER