Skip to content

Commit

Permalink
No need to run a GC when disabling majors
Browse files Browse the repository at this point in the history
run one when re-enabling instead
  • Loading branch information
eightbitraptor committed Apr 24, 2024
1 parent 37d5dee commit 3c4808d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion gc.c
Original file line number Diff line number Diff line change
Expand Up @@ -11301,7 +11301,7 @@ VALUE
rb_objspace_gc_disable_major(rb_objspace_t *objspace)
{
int old = dont_major_val();
rb_gc_start();
//rb_gc_start();
dont_major_on();
return RBOOL(old);
}
Expand All @@ -11318,6 +11318,7 @@ rb_objspace_gc_enable_major(rb_objspace_t *objspace)
{
int old = dont_major_val();
dont_major_off();
rb_gc_start();
return RBOOL(old);
}

Expand Down

0 comments on commit 3c4808d

Please sign in to comment.