Skip to content

Commit

Permalink
Predefine recursive key ID
Browse files Browse the repository at this point in the history
  • Loading branch information
nobu committed Jul 27, 2021
1 parent 19a1f46 commit 5b6f833
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 1 addition & 0 deletions defs/id.def
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ firstline, predefined = __LINE__+1, %[\
send
__send__
__attached__
__recursive_key__
initialize
initialize_copy
initialize_clone
Expand Down
3 changes: 1 addition & 2 deletions thread.c
Original file line number Diff line number Diff line change
Expand Up @@ -3471,7 +3471,7 @@ rb_thread_to_s(VALUE thread)
}

/* variables for recursive traversals */
static ID recursive_key;
#define recursive_key id__recursive_key__

static VALUE
threadptr_local_aref(rb_thread_t *th, ID id)
Expand Down Expand Up @@ -5516,7 +5516,6 @@ Init_Thread(void)
rb_define_const(cThGroup, "Default", th->thgroup);
}

recursive_key = rb_intern_const("__recursive_key__");
rb_eThreadError = rb_define_class("ThreadError", rb_eStandardError);

/* init thread core */
Expand Down

0 comments on commit 5b6f833

Please sign in to comment.