OSDN Git Service
(root)
/
pf3gnuchains
/
gcc-fork.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
cp:
[pf3gnuchains/gcc-fork.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.pt
/
expr3.C
1
// Build don't link:
2
3
template <int I>
4
struct S {};
5
6
template <int J>
7
void foo(S<J - 1>);
8
9
template <class T>
10
void baz(S<sizeof(T)>);
11
12
template <int J>
13
void fun(S<J>, S<J * 2>);
14
15
void bar()
16
{
17
foo<5>(S<4>()); // OK - 4 is 5 - 1.
18
baz<int>(S<sizeof(int)>()); // OK
19
fun(S<4>(), S<8>()); // OK - deduce J from first argument.
20
}