diff options
-rw-r--r-- | ChangeLog | 10 | ||||
-rw-r--r-- | eval_intern.h | 2 | ||||
-rw-r--r-- | thread.c | 4 |
3 files changed, 12 insertions, 4 deletions
@@ -1,3 +1,10 @@ +Wed Mar 11 03:52:12 2015 Koichi Sasada <ko1@atdot.net> + + * eval_intern.h (THROW_DATA_P): use RB_TYPE_P() instead of + BUILTIN_TYPE(). + + * thread.c (thread_join): use THROW_DATA_P(). + Wed Mar 11 03:48:01 2015 Koichi Sasada <ko1@atdot.net> * proc.c: use RUBY_VM_IFUNC_P() to recognize IFUNC or not. @@ -8,7 +15,8 @@ Wed Mar 11 03:48:01 2015 Koichi Sasada <ko1@atdot.net> * vm_insnhelper.c: ditto. - * vm_core.h: use RB_TYPE_P() instead of BUILTIN_TYPE(). + * vm_core.h (RUBY_VM_IFUNC_P): use RB_TYPE_P() instead of + BUILTIN_TYPE(). Wed Mar 11 03:21:37 2015 Koichi Sasada <ko1@atdot.net> diff --git a/eval_intern.h b/eval_intern.h index 8a43733e3d..605c2aa2ed 100644 --- a/eval_intern.h +++ b/eval_intern.h @@ -199,7 +199,7 @@ enum ruby_tag_type { #define TAG_FATAL RUBY_TAG_FATAL #define TAG_MASK RUBY_TAG_MASK -#define THROW_DATA_P(err) (BUILTIN_TYPE(err) == T_NODE) +#define THROW_DATA_P(err) RB_TYPE_P((err), T_NODE) #define SCOPE_TEST(f) (CREF_VISI(rb_vm_cref()) & (f)) #define SCOPE_CHECK(f) (CREF_VISI(rb_vm_cref()) == (f)) @@ -892,8 +892,8 @@ thread_join(rb_thread_t *target_th, double delay) rb_bug("thread_join: Fixnum (%d) should not reach here.", FIX2INT(err)); } } - else if (RB_TYPE_P(target_th->errinfo, T_NODE)) { - rb_bug("thread_join: NODE should not reach here."); + else if (THROW_DATA_P(target_th->errinfo)) { + rb_bug("thread_join: THROW_DATA should not reach here."); } else { /* normal exception */ |