blob: 74726a99cadd989effc10fcd22dd24ba3811bdab (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
// Negative explicit conv test.
// { dg-options "-std=c++0x" }
struct A {
A(const A&, int = 0); // { dg-message "candidates" }
};
struct B
{
explicit operator A();
};
int main()
{
B b;
(A(b)); // OK
(A(b,1)); // { dg-error "no match" }
}
|