diff options
Diffstat (limited to 'eval_intern.h')
-rw-r--r-- | eval_intern.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/eval_intern.h b/eval_intern.h index 2bc529db9..157e7a58b 100644 --- a/eval_intern.h +++ b/eval_intern.h @@ -117,6 +117,14 @@ char *strrchr _((const char *, const char)); #include <sys/stat.h> +#define SAVE_ROOT_JMPBUF(th, stmt) do \ + if (ruby_setjmp((th)->root_jmpbuf) == 0) { \ + stmt; \ + } \ + else { \ + rb_fiber_start(th); \ + } while (0) + #define TH_PUSH_TAG(th) do { \ rb_thread_t * const _th = th; \ struct rb_vm_tag _tag; \ |