aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.brendan/new-array.C
blob: 5341010822c51cda0bff5e3e0177e4a5553ea2c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Build don't link: 
// GROUPS passed operator-new
typedef struct {
	int a;
} AStruct;

void MakeBug() {
	AStruct *job;

	// This used to crash, it should now give error(s).
	job = new AStruct[];// ERROR - .*

	job = new AStruct;
}

main () {
	MakeBug();
}