Richard Smith | 762bb9d | 2011-10-13 22:29:44 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -fsyntax-only -verify -std=c++11 %s |
Douglas Gregor | 84fb9c0 | 2009-11-23 13:46:08 +0000 | [diff] [blame] | 2 | |
3 | // PR5518 | ||||
4 | struct A { | ||||
5 | explicit operator int(); // expected-note{{conversion to integral type}} | ||||
6 | }; | ||||
7 | |||||
8 | void x() { | ||||
9 | switch(A()) { // expected-error{{explicit conversion to}} | ||||
10 | } | ||||
11 | } |