repo.or.cz
/
gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Daily bump.
[gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
cpp0x
/
scoped_enum10.C
blob
054b90850d85a372405eb8b7925032cef6759ec0
1
// PR c++/92032 - DR 1601: Promotion of enumeration with fixed underlying type.
2
// { dg-do compile { target c++11 } }
3
4
enum E : char { e };
5
enum F : int { f };
6
enum G : long { g };
7
enum H : unsigned { h };
8
9
int f1(char);
10
void f1(int);
11
12
void f2(int);
13
int f2(char);
14
15
int f3(int);
16
void f3(short);
17
18
int f4(long);
19
void f4(int);
20
21
void f5(unsigned);
22
int f5(int);
23
24
int f6(unsigned);
25
void f6(int);
26
27
void
28
test ()
29
{
30
int r = 0;
31
r += f1 (e);
32
r += f2 (e);
33
r += f3 (f);
34
r += f4 (g);
35
r += f5 (f);
36
r += f6 (h);
37
}