blob: 3967699dd0362dbff61a7fad81ed91f5f9c789f4 [file] [log] [blame]
// PR c++/51912
// { dg-do compile { target c++11 } }
constexpr double g() { return 2.0; }
void f(int i)
{
switch (i)
{
case 1.0:; // { dg-error "could not convert" }
}
switch (i)
{
case g():; // { dg-error "could not convert" }
}
}