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
* c-common.c (get_priority): Add check for
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.pt
/
explicit17.C
blob
9a83fb0c419f547e3d3787c8cfe5f2f0c191b367
1
// { dg-do assemble }
2
// { dg-options "-ansi -pedantic-errors -w" }
3
// GROUPS passed templates
4
template <class T, class U>
5
void foo(U u, T t);
6
7
template <class T>
8
void foo(T t);
9
10
template <class T>
11
struct S {};
12
13
template <class T>
14
void foo(const S<T>&);
15
16
void bar()
17
{
18
void (*fn)(double, int) =
19
(void (*)(double, int)) &foo<int>;
20
void (*fn2)(double) = foo<double>;
21
foo<int>(3, 3.0);
22
foo<int>(S<int>());
23
}