summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/other/new1.C
blob: 71383706ea4efc662ed34ac8f5bce3e15676b3b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// PR c++/28267
// { dg-do compile }

struct A
{
  A();
  void* operator new(__SIZE_TYPE__, int = X);  // { dg-error "not declared" }
  void operator delete(void*, int);
};

void foo()
{
  new A;	// { dg-error "default argument" }
}