Mercurial > hg > Members > Moririn
annotate src/include/origin_cs.h @ 13:a765eb7f3b7c
implement delete, traverse
author | Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 07 Apr 2015 15:39:14 +0900 |
parents | |
children | 907c69e21e56 |
rev | line source |
---|---|
13
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
1 __code start_code(); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
2 __code meta_start_code(); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
3 __code exit_code(); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
4 |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
5 __code start_code(Context* context, __code (*next)()) { |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
6 goto meta_start_code(context, next); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
7 } |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
8 |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
9 __code meta_start_code(Context* context, __code (*next)()) { |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
10 context->next = next; |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
11 goto context->next(context); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
12 } |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
13 |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
14 __code exit_code(Context* context) { |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
15 free(context->ds_heap); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
16 free(context->mds_heap); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
17 goto exit(0); |
a765eb7f3b7c
implement delete, traverse
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents:
diff
changeset
|
18 } |