summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/expr/cond8.C
blob: 3e089537ff86048b27800df3fc2ff0f15f8e25e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// PR c++/22434
// { dg-options "" }

struct A
{
  A(void*);			// { dg-message "initializing" }
  ~A();
};

void foo(const int i, bool b)
{
  b ? A(0) : i; // { dg-error "conversion" }
}