summaryrefslogtreecommitdiff
path: root/string.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-12-04 16:39:07 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-12-04 16:39:07 +0000
commit53e7e2d2a136c1aa4b859fc7e6590ef793c6bd11 (patch)
tree61863eca2f0e311fbe56a0659788a6e305a76f16 /string.c
parenta9a4435e12ea2ea02d387b1599c855b28ff10757 (diff)
* string.c (sym_to_proc): tabified.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20529 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'string.c')
-rw-r--r--string.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/string.c b/string.c
index d652124879..b4963b0ce7 100644
--- a/string.c
+++ b/string.c
@@ -6922,9 +6922,9 @@ sym_to_proc(VALUE sym)
VALUE *aryp;
if (!sym_proc_cache) {
- sym_proc_cache = rb_ary_tmp_new(SYM_PROC_CACHE_SIZE * 2);
- rb_gc_register_mark_object(sym_proc_cache);
- rb_ary_store(sym_proc_cache, SYM_PROC_CACHE_SIZE*2 - 1, Qnil);
+ sym_proc_cache = rb_ary_tmp_new(SYM_PROC_CACHE_SIZE * 2);
+ rb_gc_register_mark_object(sym_proc_cache);
+ rb_ary_store(sym_proc_cache, SYM_PROC_CACHE_SIZE*2 - 1, Qnil);
}
id = SYM2ID(sym);
@@ -6932,13 +6932,13 @@ sym_to_proc(VALUE sym)
aryp = RARRAY_PTR(sym_proc_cache);
if (aryp[index] == sym) {
- return aryp[index + 1];
+ return aryp[index + 1];
}
else {
- proc = rb_proc_new(sym_call, (VALUE)id);
- aryp[index] = sym;
- aryp[index + 1] = proc;
- return proc;
+ proc = rb_proc_new(sym_call, (VALUE)id);
+ aryp[index] = sym;
+ aryp[index + 1] = proc;
+ return proc;
}
}