[Reland][Runtimes] Merge 'compile_commands.json' files from runtimes build (#116303)
[llvm-project.git] / clang / test / CodeGenCXX / instantiate-init.cpp
blobd303938c0984db9517f8201e34479abe4b7e5d59
1 // RUN: %clang_cc1 -triple x86_64-linux -std=c++14 %s -emit-llvm -o - | FileCheck %s
2 // RUN: %clang_cc1 -triple x86_64-linux -std=c++17 %s -emit-llvm -o - | FileCheck %s
4 namespace std {
5 template<typename T> class initializer_list {
6 const T *data;
7 __SIZE_TYPE__ size;
9 public:
10 initializer_list();
14 namespace ParenBraceInitList {
15 struct Vector {
16 Vector(std::initializer_list<int>);
17 ~Vector();
20 struct Base { Base(Vector) {} };
22 // CHECK: define {{.*}}18ParenBraceInitList1fILi0EE
23 template<int> void f() {
24 // CHECK: call {{.*}}18ParenBraceInitList6VectorC1
25 // CHECK: call {{.*}}18ParenBraceInitList6VectorD1
26 Base({0});
28 template void f<0>();