diff options
author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-05-27 19:12:43 +0000 |
---|---|---|
committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-05-27 19:12:43 +0000 |
commit | 57062d91b9bfb1688151cd2393011504fd26f0d8 (patch) | |
tree | 586958dc0f4d60d96f50d9a30ebfcc20b88f9d5a /yarvcore.h | |
parent | b69b1af65002e9a70a4f33bafa35593b4618e7a4 (diff) | |
download | ruby-57062d91b9bfb1688151cd2393011504fd26f0d8.tar.gz |
* cont.c: support Fiber. Check test/ruby/test_fiber.rb for detail.
Fiber is known as "Micro Thread", "Coroutine", and other terms.
At this time, only Fiber#pass is supported to change context.
I want to know more suitable method name/API for Fiber (... do you
know more suitable class name instead of Fiber?) as "suspend/resume",
"call", "yield", "start/kick/stop/restart", ....
* eval.c, eval_intern.h, thread.c, yarvcore.c, yarvcore.h: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12395 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'yarvcore.h')
-rw-r--r-- | yarvcore.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/yarvcore.h b/yarvcore.h index ba99c8a2a5..bb4cfcf086 100644 --- a/yarvcore.h +++ b/yarvcore.h @@ -497,6 +497,11 @@ struct rb_thread_struct rb_event_flag_t event_flags; int tracing; + /* fiber */ + VALUE fiber; + VALUE root_fiber; + rb_jmpbuf_t root_jmpbuf; + /* misc */ int method_missing_reason; int abort_on_exception; |