New testcase, distilled from ed-0.2
[oota-llvm.git] / test / CFrontend / 2002-11-07-Redefinition.c
1 /* Provide Declarations */
2
3 #ifndef NULL
4 #define NULL 0
5 #endif
6
7 #ifndef __cplusplus
8 typedef unsigned char bool;
9 #endif
10
11
12 /* Support for floating point constants */
13 typedef unsigned long long ConstantDoubleTy;
14 typedef unsigned int        ConstantFloatTy;
15
16
17 /* Global Declarations */
18
19 /* External Global Variable Declarations */
20
21 /* Function Declarations */
22 void __main();
23 int printf(signed char *, ...);
24 void testfunc(short l5_s, float l11_X, signed char l3_C, signed long long l9_LL, int l7_I, double l12_D);
25 void main();
26
27 /* Malloc to make sun happy */
28 extern void * malloc(size_t);
29
30
31
32 /* Global Variable Declerations */
33 extern signed char l27_d_LC0[26];
34
35
36 /* Global Variable Definitions and Initialization */
37 static signed char l27_d_LC0[26] = "%d, %f, %d, %lld, %d, %f\n";
38
39
40 /* Function Bodies */
41 void testfunc(short l5_s, float l11_X, signed char l3_C, signed long long l9_LL, int l7_I, double l12_D) {
42   int l7_reg226;
43
44
45   l7_reg226 = printf((&(l27_d_LC0[0ll])), ((unsigned )l5_s), ((double )l11_X), ((unsigned )l3_C), l9_LL, l7_I, l12_D);
46   return;
47 }
48
49 void main() {
50
51   const ConstantFloatTy FloatConstant0 = 0x3f9f5c29;    /* 1.245 */
52   const ConstantDoubleTy FloatConstant1 = 0x432ff973cafa8000;    /* 4.5e+15 */
53
54   __main();
55   testfunc(12, (*(float*)&FloatConstant0), 120, 123456677890ll, -10, (*(double*)&FloatConstant1));
56   return;
57 }
58