diff options
| author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-27 06:27:39 +0000 |
|---|---|---|
| committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-27 06:27:39 +0000 |
| commit | a9f1a3c3b84d05a1b0184c42f3191559202974a4 (patch) | |
| tree | e38ce9dc8c3ced6336d596375822c62d093df6be /include/ruby | |
| parent | 6c43158cfdc92bcbcb793dbe9144689b01413ec6 (diff) | |
| download | ruby-a9f1a3c3b84d05a1b0184c42f3191559202974a4.tar.gz ruby-a9f1a3c3b84d05a1b0184c42f3191559202974a4.tar.xz ruby-a9f1a3c3b84d05a1b0184c42f3191559202974a4.zip | |
* encoding.c (rb_enc_codelen): show codepoint in error message.
* include/ruby/encoding.h (rb_enc_codelen): comment it returns
positive integer.
* string.c (rb_str_concat): rb_enc_codelen doesn't return 0.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14733 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include/ruby')
| -rw-r--r-- | include/ruby/encoding.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/ruby/encoding.h b/include/ruby/encoding.h index 1b1e3d7c5..1a5787655 100644 --- a/include/ruby/encoding.h +++ b/include/ruby/encoding.h @@ -87,7 +87,7 @@ int rb_enc_ascget(const char *p, const char *e, int *len, rb_encoding *enc); int rb_enc_codepoint(const char *p, const char *e, rb_encoding *enc); #define rb_enc_mbc_to_codepoint(p, e, enc) ONIGENC_MBC_TO_CODE(enc,(UChar*)(p),(UChar*)(e)) -/* -> codelen or raise exception */ +/* -> codelen>0 or raise exception */ int rb_enc_codelen(int code, rb_encoding *enc); /* code,ptr,encoding -> write buf */ |
