summaryrefslogtreecommitdiffstats
path: root/encoding.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-03-15 09:19:38 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-03-15 09:19:38 +0000
commit0bed7f6c4fee2d176a235131d9613dd04d9f3f08 (patch)
tree12a9781b6b71282f477cc54e3a9825ea067ef54a /encoding.c
parent6f94b4e8964b5ebc2a401408489e3365887066e4 (diff)
downloadruby-0bed7f6c4fee2d176a235131d9613dd04d9f3f08.tar.gz
ruby-0bed7f6c4fee2d176a235131d9613dd04d9f3f08.tar.xz
ruby-0bed7f6c4fee2d176a235131d9613dd04d9f3f08.zip
* encoding.c (rb_enc_associate_index): pass unnecessary enc_capable().
* string.c (rb_str_cmp): reduce invocation of rb_enc_compatible(). git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15782 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'encoding.c')
-rw-r--r--encoding.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/encoding.c b/encoding.c
index 92ed9db1d..c7881a8ed 100644
--- a/encoding.c
+++ b/encoding.c
@@ -615,7 +615,7 @@ void
rb_enc_associate_index(VALUE obj, int idx)
{
enc_check_capable(obj);
- if (rb_enc_get_index(obj) == idx)
+ if (rb_enc_internal_get_index(obj) == idx)
return;
if (!ENC_CODERANGE_ASCIIONLY(obj) ||
!rb_enc_asciicompat(rb_enc_from_index(idx))) {