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
FSF GCC merge 02/23/03
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.pt
/
enum7.C
blob
d2ea2016d7d7c362435f3a2e96b6a88f74ba41c2
1
template <int I>
2
int f()
3
{
4
enum E { a = I };
5
6
struct S {
7
int g() {
8
E e;
9
e = a;
10
return (int) e;
11
}
12
};
13
14
S s;
15
16
return s.g();
17
}
18
19
20
int main()
21
{
22
if (f<7>() != 7)
23
return 1;
24
if (f<-3>() != -3)
25
return 1;
26
return 0;
27
}