repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Merged revisions 208012,208018-208019,208021,208023-208030,208033,208037,208040-20804...
[official-gcc.git]
/
main
/
gcc
/
testsuite
/
g++.dg
/
cpp1y
/
auto-fn20.C
blob
818b6f5da67e7a47aa80e78125b63891b65bed22
1
// { dg-do compile { target c++1y } }
2
3
template <class T>
4
auto f(T) { return 42; }
5
template <class T>
6
auto g(T) { return 0.0; }
7
8
int main()
9
{
10
int (*p)(int) = &f; // OK
11
p = &g; // { dg-error "no match" }
12
}