1 /* -fshort-enums should affect only the type with which an enum is
2     compatible, not the type of the enumeration constants which should
3     still be int.  Bug 17844.  */
4 /* Origin: Joseph Myers <jsm@polyomino.org.uk> */
5 /* { dg-do compile } */
6 /* { dg-options "-fshort-enums" } */
7 
8 enum e { A, B };
9 
10 enum e ev;
11 unsigned char uv;
12 enum e *ep = &uv;
13 unsigned char *up = &ev;
14 
15 int i;
16 __typeof__(A) te;
17 int *ip = &te;
18 __typeof__(B) *tep = &i;
19 
20 int x[((sizeof(A) == sizeof(int)) ? 1 : -1)];
21