diff options
| author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-10-16 17:50:51 +0000 |
|---|---|---|
| committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-10-16 17:50:51 +0000 |
| commit | b19494fd6ad74da9871b6d4339c3b6e612d980a7 (patch) | |
| tree | 518cdcd64cc1c2ca082d86ec54b16ef4d478d2e9 /string.c | |
| parent | 3d563fff7f0a0fcb3cb9e3727f0e78e408a11a95 (diff) | |
| download | ruby-b19494fd6ad74da9871b6d4339c3b6e612d980a7.tar.gz ruby-b19494fd6ad74da9871b6d4339c3b6e612d980a7.tar.xz ruby-b19494fd6ad74da9871b6d4339c3b6e612d980a7.zip | |
* string.c (rb_str_ord): use encoding.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@13726 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'string.c')
| -rw-r--r-- | string.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -4751,7 +4751,7 @@ rb_str_ord(VALUE s) { int c; - c = RSTRING_PTR(s)[0] & 0xff; + c = rb_enc_codepoint(RSTRING_PTR(s), RSTRING_END(s), rb_enc_get(s)); return INT2NUM(c); } /* |
