summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNobuyoshi Nakada <[email protected]>2025-06-14 15:53:25 +0900
committerNobuyoshi Nakada <[email protected]>2025-06-14 15:53:25 +0900
commit32737f8a1728e2d3841f24cbf17f799abd29251a (patch)
tree23523261a65617d4d9cc3009e1e06327800067f0
parent39697ffd01f98b888a5585547ef8cbee4199c583 (diff)
Adjust indent [ci skip]HEADmaster
-rw-r--r--ractor.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/ractor.c b/ractor.c
index 3eedf59048..cce376c543 100644
--- a/ractor.c
+++ b/ractor.c
@@ -1358,24 +1358,24 @@ make_shareable_check_shareable(VALUE obj)
}
switch (TYPE(obj)) {
- case T_IMEMO:
- return traverse_skip;
- case T_OBJECT:
- {
- // If a T_OBJECT is shared and has no free capacity, we can't safely store the object_id inline,
- // as it would require to move the object content into an external buffer.
- // This is only a problem for T_OBJECT, given other types have external fields and can do RCU.
- // To avoid this issue, we proactively create the object_id.
- shape_id_t shape_id = RBASIC_SHAPE_ID(obj);
- attr_index_t capacity = RSHAPE_CAPACITY(shape_id);
- attr_index_t free_capacity = capacity - RSHAPE_LEN(shape_id);
- if (!rb_shape_has_object_id(shape_id) && capacity && !free_capacity) {
- rb_obj_id(obj);
- }
- }
- break;
- default:
- break;
+ case T_IMEMO:
+ return traverse_skip;
+ case T_OBJECT:
+ {
+ // If a T_OBJECT is shared and has no free capacity, we can't safely store the object_id inline,
+ // as it would require to move the object content into an external buffer.
+ // This is only a problem for T_OBJECT, given other types have external fields and can do RCU.
+ // To avoid this issue, we proactively create the object_id.
+ shape_id_t shape_id = RBASIC_SHAPE_ID(obj);
+ attr_index_t capacity = RSHAPE_CAPACITY(shape_id);
+ attr_index_t free_capacity = capacity - RSHAPE_LEN(shape_id);
+ if (!rb_shape_has_object_id(shape_id) && capacity && !free_capacity) {
+ rb_obj_id(obj);
+ }
+ }
+ break;
+ default:
+ break;
}
if (!RB_OBJ_FROZEN_RAW(obj)) {