aboutsummaryrefslogtreecommitdiff
path: root/clang/test/AST/issue53742.cpp
blob: 93978f2bcc11d46cd1d293acdf19675a6846da54 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// RUN: %clang_cc1 -fsyntax-only %s -verify

struct Data {
  char *a;
  char *b;
  bool *c;
};

int main() {
  Data in;
  in.a = new char[](); // expected-error {{cannot determine allocated array size from initializer}}
  in.c = new bool[100]();
  in.b = new char[100]();
}