summaryrefslogtreecommitdiff
path: root/vm.c
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2021-03-09 16:29:50 +0900
committerJeremy Evans <code@jeremyevans.net>2021-07-01 18:49:17 -0700
commit8ebb5e23ebc5f1675e3479b9a29f124dc458226b (patch)
treec751532653c9b626b875733079471eabd17b5012 /vm.c
parent1862d961a9b18acbf30d9391e091d91de9c0f16d (diff)
Keep GC disabled until VM bootstrap has done [Bug #17583]
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/4617
Diffstat (limited to 'vm.c')
-rw-r--r--vm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/vm.c b/vm.c
index 3963d67168..b12021668c 100644
--- a/vm.c
+++ b/vm.c
@@ -3669,6 +3669,8 @@ Init_VM(void)
* The Binding of the top level scope
*/
rb_define_global_const("TOPLEVEL_BINDING", rb_binding_new());
+
+ rb_objspace_gc_enable(vm->objspace);
}
vm_init_redefined_flag();
@@ -3734,8 +3736,6 @@ Init_vm_objects(void)
vm->mark_object_ary = rb_ary_tmp_new(128);
vm->loading_table = st_init_strtable();
vm->frozen_strings = st_init_table_with_size(&rb_fstring_hash_type, 10000);
-
- rb_objspace_gc_enable(vm->objspace);
}
/* top self */