]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/testsuite/gdb.base/shr1.c
run copyright.sh for 2011.
[thirdparty/binutils-gdb.git] / gdb / testsuite / gdb.base / shr1.c
CommitLineData
c906108c
SS
1#include "ss.h"
2#include <stdio.h>
3
4typedef float f;
5
6float sg = 5.5;
7int sgi = 2;
8static int sgs = 7;
9
085dd6e6
JM
10#ifdef PROTOTYPES
11int shr1(int x)
12#else
c906108c
SS
13int shr1(x)
14int x;
085dd6e6 15#endif
c906108c
SS
16{
17 f mumble;
18 int l;
19 l = 1;
20 {
21 int l;
22 l = 2;
23 }
24 mumble = 7.7;
25 sg = 6.6;
26 sgi++;
27 sgs = 8;
c2d494a0 28 printf("address of sgs is %p\n", &sgs);
c906108c
SS
29 return 2*x;
30}
31
085dd6e6
JM
32#ifdef PROTOTYPES
33static int shr1_local(int x)
34#else
c906108c
SS
35static int shr1_local(x)
36int x;
085dd6e6 37#endif
c906108c
SS
38{
39 return 2*x;
40}
41
085dd6e6
JM
42#ifdef PROTOTYPES
43int structarg(struct s x)
44#else
c906108c
SS
45int structarg(x)
46struct s x;
085dd6e6 47#endif
c906108c
SS
48{
49 return x.a;
50}
51
085dd6e6
JM
52#ifdef PROTOTYPES
53int pstructarg(struct s *x)
54#else
c906108c
SS
55int pstructarg(x)
56struct s *x;
085dd6e6 57#endif
c906108c
SS
58{
59 return x->a;
60}
61
62
63