summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.brendan/crash29.C
blob: 38c9d49a19ded350b9e1ae6bea91a6022d1ba05b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// { dg-do assemble  }
// GROUPS passed old-abort

union Value
{
	Value(){}
};

struct GlobalAddress		// { dg-message "note" }
{
	GlobalAddress(Value *nvar){} // { dg-message "note" }
};

int
main()
{
	new GlobalAddress(Value());		// internal error occured here// { dg-error "no matching" }
	// { dg-message "candidate" "candidate note" { target *-*-* } 17 }
	//new GlobalAddress(new Value());	// This line is correct code
}