Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/gcc.dg/pr59418.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
68:561a7518be6b | 111:04ced10e8804 |
---|---|
1 /* PR debug/59418 */ | |
2 /* Reported by Ryan Mansfield <rmansfield@qnx.com> */ | |
3 | |
4 /* { dg-do compile } */ | |
5 /* { dg-options "-Os -g" } */ | |
6 /* { dg-options "-march=armv7-a+fp -mfloat-abi=hard -Os -g" { target { arm*-*-* && { ! arm_thumb1 } } } } */ | |
7 | |
8 extern int printf (const char *__format, ...); | |
9 double bar (const char *, int); | |
10 | |
11 void | |
12 foo (const char *pptr, int caplen) | |
13 { | |
14 int type; | |
15 const char *tptr; | |
16 if (caplen < 4) | |
17 { | |
18 (void) printf ("foo"); | |
19 return; | |
20 } | |
21 while (tptr < pptr) | |
22 { | |
23 switch (type) | |
24 { | |
25 case 0x01: | |
26 printf (""); | |
27 case 0x0b: | |
28 printf (""); | |
29 case 0x0e: | |
30 printf (""); | |
31 case 0x10: | |
32 printf ("%1.2fW", bar (tptr, caplen) / 1000.0); | |
33 } | |
34 } | |
35 printf ("foo"); | |
36 } |