| 1 |
// DR2327: In direct-initialization, prefer a constructor even if it requires a |
| 2 |
// qualification conversion. |
| 3 |
|
| 4 |
// { dg-do compile { target c++11 } } |
| 5 |
|
| 6 |
struct Dog; |
| 7 |
struct Cat { |
| 8 |
Cat(const Dog&); |
| 9 |
}; |
| 10 |
struct Dog { |
| 11 |
operator Cat() = delete; |
| 12 |
}; |
| 13 |
|
| 14 |
Cat cat(Dog{}); |