blob: 1badd6a5e81e19aeae455177fc9952d5ba1482c3 [file] [log] [blame]
// { dg-do compile { target c++1y } }
auto f() { return 42; } // { dg-message "old declaration .auto" }
auto f(); // OK
int f(); // { dg-error "new declaration" }
template <class T> auto f(T t) { return t; }
template <class T> T f(T t);
int main()
{
f(42); // { dg-error "ambiguous" }
}