annotate test/tmp6.c @ 0:d35df41eac69

Initial revision
author kono
date Thu, 13 Jan 2000 02:41:41 +0900
parents
children bf602558130d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
1 #include "stdio.h"
d35df41eac69 Initial revision
kono
parents:
diff changeset
2
d35df41eac69 Initial revision
kono
parents:
diff changeset
3 int
d35df41eac69 Initial revision
kono
parents:
diff changeset
4 main(ac,av)
d35df41eac69 Initial revision
kono
parents:
diff changeset
5 int ac;
d35df41eac69 Initial revision
kono
parents:
diff changeset
6 char *av[];
d35df41eac69 Initial revision
kono
parents:
diff changeset
7 {
d35df41eac69 Initial revision
kono
parents:
diff changeset
8 int i;
d35df41eac69 Initial revision
kono
parents:
diff changeset
9
d35df41eac69 Initial revision
kono
parents:
diff changeset
10 if(ac!=2)
d35df41eac69 Initial revision
kono
parents:
diff changeset
11 return(0);
d35df41eac69 Initial revision
kono
parents:
diff changeset
12 i=main0(ac,av,return,environment);
d35df41eac69 Initial revision
kono
parents:
diff changeset
13 fprintf(stderr,"1: %s %d\n",av[0],i);
d35df41eac69 Initial revision
kono
parents:
diff changeset
14 return i;
d35df41eac69 Initial revision
kono
parents:
diff changeset
15 }
d35df41eac69 Initial revision
kono
parents:
diff changeset
16
d35df41eac69 Initial revision
kono
parents:
diff changeset
17 int
d35df41eac69 Initial revision
kono
parents:
diff changeset
18 main0(ac,av,ret,retenv)
d35df41eac69 Initial revision
kono
parents:
diff changeset
19 int ac;
d35df41eac69 Initial revision
kono
parents:
diff changeset
20 char *av[];
d35df41eac69 Initial revision
kono
parents:
diff changeset
21 code (*ret)();
d35df41eac69 Initial revision
kono
parents:
diff changeset
22 void *retenv;
d35df41eac69 Initial revision
kono
parents:
diff changeset
23 {
d35df41eac69 Initial revision
kono
parents:
diff changeset
24 int i,j,k;
d35df41eac69 Initial revision
kono
parents:
diff changeset
25 i=123;
d35df41eac69 Initial revision
kono
parents:
diff changeset
26 j=456;
d35df41eac69 Initial revision
kono
parents:
diff changeset
27 k = atoi(av[1]);
d35df41eac69 Initial revision
kono
parents:
diff changeset
28 fprintf(stderr,"2: av=%x av[0]=%x %s\n",av,av[0],av[0]);
d35df41eac69 Initial revision
kono
parents:
diff changeset
29 goto code0(i,j,k,av,ret,retenv,return,environment);
d35df41eac69 Initial revision
kono
parents:
diff changeset
30 }
d35df41eac69 Initial revision
kono
parents:
diff changeset
31
d35df41eac69 Initial revision
kono
parents:
diff changeset
32 code code0(i,j,k,av,ret,retenv,ret1,ret1env)
d35df41eac69 Initial revision
kono
parents:
diff changeset
33 int i,j,k;
d35df41eac69 Initial revision
kono
parents:
diff changeset
34 char *av[];
d35df41eac69 Initial revision
kono
parents:
diff changeset
35 code (*ret)();
d35df41eac69 Initial revision
kono
parents:
diff changeset
36 void *retenv;
d35df41eac69 Initial revision
kono
parents:
diff changeset
37 code (*ret1)();
d35df41eac69 Initial revision
kono
parents:
diff changeset
38 void *ret1env;
d35df41eac69 Initial revision
kono
parents:
diff changeset
39 {
d35df41eac69 Initial revision
kono
parents:
diff changeset
40 char *p;
d35df41eac69 Initial revision
kono
parents:
diff changeset
41 p = av[0];
d35df41eac69 Initial revision
kono
parents:
diff changeset
42 fprintf(stderr,"3: i=%d j=%d k=%d av=%x p=%s\n",i,j,k,av,p);
d35df41eac69 Initial revision
kono
parents:
diff changeset
43 goto code1(i,j,k,av,ret,retenv,ret1,ret1env);
d35df41eac69 Initial revision
kono
parents:
diff changeset
44 }
d35df41eac69 Initial revision
kono
parents:
diff changeset
45
d35df41eac69 Initial revision
kono
parents:
diff changeset
46 code code1(i,j,k,av,ret,retenv,ret1,ret1env)
d35df41eac69 Initial revision
kono
parents:
diff changeset
47 int i,j,k;
d35df41eac69 Initial revision
kono
parents:
diff changeset
48 char *av[];
d35df41eac69 Initial revision
kono
parents:
diff changeset
49 code (*ret)();
d35df41eac69 Initial revision
kono
parents:
diff changeset
50 void *retenv;
d35df41eac69 Initial revision
kono
parents:
diff changeset
51 code (*ret1)();
d35df41eac69 Initial revision
kono
parents:
diff changeset
52 void *ret1env;
d35df41eac69 Initial revision
kono
parents:
diff changeset
53 {
d35df41eac69 Initial revision
kono
parents:
diff changeset
54 fprintf(stderr,"4: %s\n",av[0]);
d35df41eac69 Initial revision
kono
parents:
diff changeset
55 goto code2(i,j,k,av,ret,retenv,ret1,ret1env);
d35df41eac69 Initial revision
kono
parents:
diff changeset
56 }
d35df41eac69 Initial revision
kono
parents:
diff changeset
57
d35df41eac69 Initial revision
kono
parents:
diff changeset
58 code code2(i,j,k,av,ret,retenv,ret1,ret1env)
d35df41eac69 Initial revision
kono
parents:
diff changeset
59 int i,j,k;
d35df41eac69 Initial revision
kono
parents:
diff changeset
60 char *av[];
d35df41eac69 Initial revision
kono
parents:
diff changeset
61 code (*ret)();
d35df41eac69 Initial revision
kono
parents:
diff changeset
62 void *retenv;
d35df41eac69 Initial revision
kono
parents:
diff changeset
63 code (*ret1)();
d35df41eac69 Initial revision
kono
parents:
diff changeset
64 void *ret1env;
d35df41eac69 Initial revision
kono
parents:
diff changeset
65 {
d35df41eac69 Initial revision
kono
parents:
diff changeset
66 fprintf(stderr,"5: %s\n",av[0]);
d35df41eac69 Initial revision
kono
parents:
diff changeset
67 fprintf(stderr,"5: i=%d j=%d k=%d av=%x\n",i,j,k,av);
d35df41eac69 Initial revision
kono
parents:
diff changeset
68 if (k>3)
d35df41eac69 Initial revision
kono
parents:
diff changeset
69 goto (*ret1)(1234),ret1env;
d35df41eac69 Initial revision
kono
parents:
diff changeset
70 goto (*ret)(1234),retenv;
d35df41eac69 Initial revision
kono
parents:
diff changeset
71 }