summaryrefslogtreecommitdiff
path: root/test/CodeGen/vla.c
blob: 907de916fa0be8cd83a9d380f688b1559a670156 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// RUN: clang %s -emit-llvm -o %t

int b(char* x);

// Extremely basic VLA test
void a(int x) {
  char arry[x];
  arry[0] = 10;
  b(arry);
}

int c(int n)
{
  return sizeof(int[n]);
}