blob: 2d6c2f287140be112069d94f3e69e42bf5222cdd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
// RUN: %clang_cc1 -fsyntax-only %s -verify
const int ksize = 42;
int size = 42;
@interface X
{
int arr1[ksize]; // expected-warning{{variable length array folded to constant array}}
int arr2[size]; // expected-error{{instance variables must have a constant size}}
int arr3[ksize-43]; // expected-error{{array size is negative}}
}
@end
|