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
new
[pf3gnuchains/gcc-fork.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.pt
/
sizeof.C
1
extern "C" void abort();
2
3
template <int I>
4
int bar() { return I; }
5
6
template <class T>
7
int foo(T)
8
{
9
return bar<sizeof(T) + 4>() + bar<sizeof(long) + 7>();
10
}
11
12
13
int main()
14
{
15
if (foo(2) != sizeof(int) + 4 + sizeof(long) + 7)
16
abort();
17
}