Mercurial > hg > CbC > CbC_gcc
comparison CbC-examples/test_para.c @ 16:4c6926a2b9bc
examples.
author | kent <kent@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 24 Sep 2009 12:51:25 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
15:11a6cbe2d14c | 16:4c6926a2b9bc |
---|---|
1 #include<stdio.h> | |
2 #include<stdlib.h> | |
3 | |
4 __code cs_exit(int a){ | |
5 printf("cs_exit was called: a=%d.\n", a); | |
6 exit(a); | |
7 } | |
8 | |
9 __code cs0(int a, double b, int c, int d){ | |
10 printf("cs0 was called: a=%d, b=%lf, c=%d, d=%d.\n", a, b, c, d); | |
11 goto cs_exit( (int)(20*a + 4.4*b + 2022/c + 28*d) ); | |
12 } | |
13 | |
14 | |
15 __code cs_goto(){ | |
16 goto cs0(11, 22.2, 33, 44); | |
17 } | |
18 | |
19 int main(int argc, char **argv){ | |
20 | |
21 printf("it is in main.\n"); | |
22 goto cs_goto(); | |
23 return 0; | |
24 } | |
25 | |
26 |