8000 mmtk: fix linking issue with shape.h · ruby/ruby@7f53212 · GitHub
[go: up one dir, main page]

Skip to content

Commit 7f53212

Browse files
committed
mmtk: fix linking issue with shape.h
1 parent fcca254 commit 7f53212

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

gc.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2092,6 +2092,12 @@ rb_obj_id(VALUE obj)
20922092
return rb_find_object_id(rb_gc_get_objspace(), obj, object_id);
20932093
}
20942094

2095+
bool
2096+
rb_obj_id_p(VALUE obj)
2097+
{
2098+
return rb_shape_obj_has_id(obj);
2099+
}
2100+
20952101
static enum rb_id_table_iterator_result
20962102
cc_table_memsize_i(VALUE ccs_ptr, void *data_ptr)
20972103
{

gc/default/default.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
#include "darray.h"
3030
#include "gc/gc.h"
3131
#include "gc/gc_impl.h"
32-
#include "shape.h"
3332

3433
#ifndef BUILDING_MODULAR_GC
3534
# include "probes.h"
@@ -6113,7 +6112,7 @@ rb_gc_impl_object_metadata(void *objspace_ptr, VALUE obj)
61136112
if (RVALUE_MARKING(objspace, obj)) SET_ENTRY(marking, Qtrue);
61146113
if (RVALUE_MARKED(objspace, obj)) SET_ENTRY(marked, Qtrue);
61156114
if (RVALUE_PINNED(objspace, obj)) SET_ENTRY(pinned, Qtrue);
6116-
if (rb_shape_obj_has_id(obj)) SET_ENTRY(object_id, rb_obj_id(obj));
6115+
if (rb_obj_id_p(obj)) SET_ENTRY(object_id, rb_obj_id(obj));
61176116
if (FL_TEST(obj, FL_SHAREABLE)) SET_ENTRY(shareable, Qtrue);
61186117

61196118
object_metadata_entries[n].name = 0;

gc/gc.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ size_t rb_obj_memsize_of(VALUE obj);
7272
void rb_gc_prepare_heap_process_object(VALUE obj);
7373
bool ruby_free_at_exit_p(void);
7474
bool rb_memerror_reentered(void);
75+
bool rb_obj_id_p(VALUE);
7576

7677
#if USE_MODULAR_GC
7778
bool rb_gc_event_hook_required_p(rb_event_flag_t event);

gc/mmtk/mmtk.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
#include "gc/gc.h"
99
#include "gc/gc_impl.h"
1010
#include "gc/mmtk/mmtk.h"
11-
#include "shape.h"
1211

1312
#include "ccan/list/list.h"
1413
#include "darray.h"
@@ -1215,7 +1214,7 @@ rb_gc_impl_object_metadata(void *objspace_ptr, VALUE obj)
12151214
n++; \
12161215
} while (0)
12171216

1218-
if (rb_shape_obj_has_id(obj)) SET_ENTRY(object_id, rb_obj_id(obj));
1217+
if (rb_obj_id_p(obj)) SET_ENTRY(object_id, rb_obj_id(obj));
12191218

12201219
object_metadata_entries[n].name = 0;
12211220
object_metadata_entries[n].val = 0;

0 commit comments

Comments
 (0)
0