`T_MOVED` should never be pushed on the mark stack

No objects should ever reference a `T_MOVED` slot.  If they do, it's
absolutely a bug.  If we kill the process when `T_MOVED` is pushed on
the mark stack it will make it easier to identify which object holds a
reference that hasn't been updated.
This commit is contained in:
Aaron Patterson 2020-05-06 15:52:37 -07:00
Родитель 1084b679bd
Коммит 00698f26a9
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 953170BCB4FFAFC6
1 изменённых файлов: 1 добавлений и 0 удалений

1
gc.c
Просмотреть файл

@ -4590,6 +4590,7 @@ push_mark_stack(mark_stack_t *stack, VALUE data)
switch (BUILTIN_TYPE(obj)) {
case T_NIL:
case T_FIXNUM:
case T_MOVED:
rb_bug("push_mark_stack() called for broken object");
break;