summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgit <svn-admin@ruby-lang.org>2022-09-27 01:21:58 +0900
committergit <svn-admin@ruby-lang.org>2022-09-27 01:21:58 +0900
commit830b5b5c351c5c6efa5ad461ae4ec5085e5f0275 (patch)
tree38bcfe1ad1ab2999966be22422c6db0f8b694bef
parent9ddfd2ca004d1952be79cf1b84c52c79a55978f4 (diff)
downloadruby-830b5b5c351c5c6efa5ad461ae4ec5085e5f0275.tar.gz
* expand tabs. [ci skip]
Tabs were expanded because the file did not have any tab indentation in unedited lines. Please update your editor config, and use misc/expand_tabs.rb in the pre-commit hook.
-rw-r--r--compile.c2
-rw-r--r--gc.c4
-rw-r--r--variable.c36
3 files changed, 21 insertions, 21 deletions
diff --git a/compile.c b/compile.c
index 01f6abe6bc..9051ecfcd6 100644
--- a/compile.c
+++ b/compile.c
@@ -2459,7 +2459,7 @@ iseq_set_sequence(rb_iseq_t *iseq, LINK_ANCHOR *const anchor)
generated_iseq[code_index + 1 + j] = (VALUE)ic;
}
break;
- case TS_IVC: /* inline ivar cache */
+ case TS_IVC: /* inline ivar cache */
{
unsigned int ic_index = FIX2UINT(operands[j]);
vm_ic_attr_index_initialize(((IVC)&body->is_entries[ic_index]), INVALID_SHAPE_ID);
diff --git a/gc.c b/gc.c
index 03f936f0d8..77e2d1aeb8 100644
--- a/gc.c
+++ b/gc.c
@@ -3779,8 +3779,8 @@ obj_free(rb_objspace_t *objspace, VALUE obj)
RB_DEBUG_COUNTER_INC(obj_imemo_shape);
break;
}
- }
- return TRUE;
+ }
+ return TRUE;
default:
rb_bug("gc_sweep(): unknown data type 0x%x(%p) 0x%"PRIxVALUE,
diff --git a/variable.c b/variable.c
index a6f6d5ec1b..abbe76eba7 100644
--- a/variable.c
+++ b/variable.c
@@ -1048,7 +1048,7 @@ rb_mark_generic_ivar(VALUE obj)
#if !SHAPE_IN_BASIC_FLAGS
rb_gc_mark((VALUE)rb_shape_get_shape_by_id(ivtbl->shape_id));
#endif
- gen_ivtbl_mark(ivtbl);
+ gen_ivtbl_mark(ivtbl);
}
}
@@ -1077,7 +1077,7 @@ rb_generic_ivar_memsize(VALUE obj)
struct gen_ivtbl *ivtbl;
if (rb_gen_ivtbl_get(obj, 0, &ivtbl))
- return gen_ivtbl_bytes(ivtbl->numiv);
+ return gen_ivtbl_bytes(ivtbl->numiv);
return 0;
}
@@ -1779,17 +1779,17 @@ rb_ivar_count(VALUE obj)
switch (BUILTIN_TYPE(obj)) {
case T_OBJECT:
- if (rb_shape_get_shape(obj)->iv_count > 0) {
- st_index_t i, count, num = ROBJECT_NUMIV(obj);
- const VALUE *const ivptr = ROBJECT_IVPTR(obj);
- for (i = count = 0; i < num; ++i) {
- if (ivptr[i] != Qundef) {
- count++;
- }
- }
- return count;
- }
- break;
+ if (rb_shape_get_shape(obj)->iv_count > 0) {
+ st_index_t i, count, num = ROBJECT_NUMIV(obj);
+ const VALUE *const ivptr = ROBJECT_IVPTR(obj);
+ for (i = count = 0; i < num; ++i) {
+ if (ivptr[i] != Qundef) {
+ count++;
+ }
+ }
+ return count;
+ }
+ break;
case T_CLASS:
case T_MODULE:
if ((tbl = RCLASS_IV_TBL(obj)) != 0) {
@@ -1800,11 +1800,11 @@ rb_ivar_count(VALUE obj)
if (FL_TEST(obj, FL_EXIVAR)) {
struct gen_ivtbl *ivtbl;
- if (rb_gen_ivtbl_get(obj, 0, &ivtbl)) {
- return gen_ivtbl_count(ivtbl);
- }
- }
- break;
+ if (rb_gen_ivtbl_get(obj, 0, &ivtbl)) {
+ return gen_ivtbl_count(ivtbl);
+ }
+ }
+ break;
}
return 0;
}