0
|
1 #include "stdio.h"
|
|
2
|
|
3 int
|
|
4 main(ac,av)
|
|
5 int ac;
|
|
6 char *av[];
|
|
7 {
|
|
8 int i;
|
|
9
|
6
|
10 if(ac!=2) {
|
|
11 fprintf(stderr,"must have one neumeric argument.\n");
|
0
|
12 return(0);
|
6
|
13 }
|
0
|
14 i=main0(ac,av,return,environment);
|
|
15 fprintf(stderr,"1: %s %d\n",av[0],i);
|
172
|
16 return 0;
|
0
|
17 }
|
|
18
|
|
19 int
|
|
20 main0(ac,av,ret,retenv)
|
|
21 int ac;
|
|
22 char *av[];
|
|
23 code (*ret)();
|
|
24 void *retenv;
|
|
25 {
|
|
26 int i,j,k;
|
|
27 i=123;
|
|
28 j=456;
|
|
29 k = atoi(av[1]);
|
|
30 fprintf(stderr,"2: av=%x av[0]=%x %s\n",av,av[0],av[0]);
|
|
31 goto code0(i,j,k,av,ret,retenv,return,environment);
|
|
32 }
|
|
33
|
|
34 code code0(i,j,k,av,ret,retenv,ret1,ret1env)
|
|
35 int i,j,k;
|
|
36 char *av[];
|
|
37 code (*ret)();
|
|
38 void *retenv;
|
|
39 code (*ret1)();
|
|
40 void *ret1env;
|
|
41 {
|
|
42 char *p;
|
|
43 p = av[0];
|
|
44 fprintf(stderr,"3: i=%d j=%d k=%d av=%x p=%s\n",i,j,k,av,p);
|
|
45 goto code1(i,j,k,av,ret,retenv,ret1,ret1env);
|
|
46 }
|
|
47
|
|
48 code code1(i,j,k,av,ret,retenv,ret1,ret1env)
|
|
49 int i,j,k;
|
|
50 char *av[];
|
|
51 code (*ret)();
|
|
52 void *retenv;
|
|
53 code (*ret1)();
|
|
54 void *ret1env;
|
|
55 {
|
|
56 fprintf(stderr,"4: %s\n",av[0]);
|
|
57 goto code2(i,j,k,av,ret,retenv,ret1,ret1env);
|
|
58 }
|
|
59
|
|
60 code code2(i,j,k,av,ret,retenv,ret1,ret1env)
|
|
61 int i,j,k;
|
|
62 char *av[];
|
|
63 code (*ret)();
|
|
64 void *retenv;
|
|
65 code (*ret1)();
|
|
66 void *ret1env;
|
|
67 {
|
|
68 fprintf(stderr,"5: %s\n",av[0]);
|
|
69 fprintf(stderr,"5: i=%d j=%d k=%d av=%x\n",i,j,k,av);
|
|
70 if (k>3)
|
|
71 goto (*ret1)(1234),ret1env;
|
|
72 goto (*ret)(1234),retenv;
|
|
73 }
|