annotate gcc/testsuite/gcc.dg/pr47446-1.c @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* { dg-do assemble } */
kono
parents:
diff changeset
2 /* { dg-options "-O2" } */
kono
parents:
diff changeset
3
kono
parents:
diff changeset
4 extern void abort (void);
kono
parents:
diff changeset
5 enum
kono
parents:
diff changeset
6 {
kono
parents:
diff changeset
7 __GCONV_OK = 0,
kono
parents:
diff changeset
8 __GCONV_NOCONV,
kono
parents:
diff changeset
9 __GCONV_NODB,
kono
parents:
diff changeset
10 __GCONV_NOMEM,
kono
parents:
diff changeset
11 __GCONV_EMPTY_INPUT,
kono
parents:
diff changeset
12 __GCONV_FULL_OUTPUT,
kono
parents:
diff changeset
13 __GCONV_ILLEGAL_INPUT,
kono
parents:
diff changeset
14 __GCONV_INCOMPLETE_INPUT,
kono
parents:
diff changeset
15 __GCONV_ILLEGAL_DESCRIPTOR,
kono
parents:
diff changeset
16 __GCONV_INTERNAL_ERROR
kono
parents:
diff changeset
17 };
kono
parents:
diff changeset
18 int
kono
parents:
diff changeset
19 foo (int result)
kono
parents:
diff changeset
20 {
kono
parents:
diff changeset
21 int irreversible = 0;
kono
parents:
diff changeset
22 switch (result)
kono
parents:
diff changeset
23 {
kono
parents:
diff changeset
24 case __GCONV_ILLEGAL_INPUT:
kono
parents:
diff changeset
25 irreversible = -1L;
kono
parents:
diff changeset
26 break;
kono
parents:
diff changeset
27 case __GCONV_FULL_OUTPUT:
kono
parents:
diff changeset
28 irreversible = -2L;
kono
parents:
diff changeset
29 break;
kono
parents:
diff changeset
30 case __GCONV_INCOMPLETE_INPUT:
kono
parents:
diff changeset
31 irreversible = -3L;
kono
parents:
diff changeset
32 break;
kono
parents:
diff changeset
33 case __GCONV_EMPTY_INPUT:
kono
parents:
diff changeset
34 case __GCONV_OK:
kono
parents:
diff changeset
35 break;
kono
parents:
diff changeset
36 default:
kono
parents:
diff changeset
37 abort ();
kono
parents:
diff changeset
38 }
kono
parents:
diff changeset
39 return irreversible;
kono
parents:
diff changeset
40 }