[clang] Handle __declspec() attributes in using
[llvm-project.git] / clang / test / CodeGenCXX / array-construction.cpp
blob53b81f2d85ba6fbf8d26764b13ec042aebea1509
1 // RUN: %clang_cc1 -triple x86_64-apple-darwin -std=c++11 -emit-llvm %s -o - | \
2 // RUN: FileCheck %s
3 // RUN: %clang_cc1 -triple i386-apple-darwin -std=c++11 -emit-llvm %s -o - | \
4 // RUN: FileCheck %s
6 extern "C" int printf(...);
8 static int count;
9 static float fcount;
11 class xpto {
12 public:
13 xpto() : i(count++), f(fcount++) {
14 printf("xpto::xpto()\n");
16 int i;
17 float f;
19 ~xpto() {
20 printf("xpto::~xpto()\n");
24 int main() {
25 xpto array[2][3][4];
26 for (int h = 0; h < 2; h++)
27 for (int i = 0; i < 3; i++)
28 for (int j = 0; j < 4; j++)
29 printf("array[%d][%d][%d] = {%d, %f}\n",
30 h, i, j, array[h][i][j].i, array[h][i][j].f);
33 // CHECK: call void @_ZN4xptoC1Ev