1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/test
akr 69406aad50 * encoding.c (rb_enc_precise_mbclen): new function for mbclen with
validation.

* include/ruby/encoding.h (rb_enc_precise_mbclen): declared.
  (MBCLEN_CHARFOUND): new macro.
  (MBCLEN_INVALID): new macro.
  (MBCLEN_NEEDMORE): new macro.

* include/ruby/oniguruma.h (OnigEncodingTypeST): replace mbc_enc_len
  by precise_mbc_enc_len.
  (ONIGENC_PRECISE_MBC_ENC_LEN): new macro.
  (ONIGENC_CONSTRUCT_MBCLEN_CHARFOUND): new macro.
  (ONIGENC_CONSTRUCT_MBCLEN_INVALID): new macro.
  (ONIGENC_CONSTRUCT_MBCLEN_NEEDMORE): new macro.
  (ONIGENC_MBCLEN_CHARFOUND): new macro.
  (ONIGENC_MBCLEN_INVALID): new macro.
  (ONIGENC_MBCLEN_NEEDMORE): new macro.
  (ONIGENC_MBC_ENC_LEN): use ONIGENC_PRECISE_MBC_ENC_LEN.

* enc/euc_jp.c: validation implemented.

* enc/sjis.c: ditto.

* enc/utf8.c: ditto.

* string.c (rb_str_inspect): use rb_enc_precise_mbclen for invalid
  encoding.
  (rb_str_valid_encoding_p): new method String#valid_encoding?.

* io.c (rb_io_getc): use rb_enc_precise_mbclen.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14119 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-12-06 09:28:26 +00:00
..
csv
dbm forgot to modify TestDBM2 and TestGDBM2. 2007-10-24 06:29:59 +00:00
digest
drb * lib/drb/extserv.rb (initialize, stop_service): synchronize with 2007-11-26 14:24:29 +00:00
erb
fileutils * test/fileutils/fileasserts.rb (assert_equal_timestamp): new assert 2007-11-21 07:40:36 +00:00
gdbm forgot to modify TestDBM2 and TestGDBM2. 2007-10-24 06:29:59 +00:00
io/nonblock use ML ref. for assertion message. 2007-11-18 07:18:56 +00:00
json * lib/json.rb, lib/json/add/{core.rb, rails.rb}, 2007-11-30 12:08:46 +00:00
logger
monitor
net * test/net/http/test_https_proxy.rb 2007-11-14 07:17:18 +00:00
nkf
openssl
optparse
ostruct
pathname fix test. 2007-11-13 14:59:02 +00:00
rdoc/parsers
readline
rinda
ripper * parse.y (parser_yylex): should clear parser->tokp as well. 2007-11-19 07:10:09 +00:00
rss * lib/rss/rss.rb, test/rss/test_version.rb: 0.2.1 -> 0.2.2. 2007-12-02 06:45:53 +00:00
ruby * encoding.c (rb_enc_precise_mbclen): new function for mbclen with 2007-12-06 09:28:26 +00:00
rubygems Import fast-loading gem_prelude.rb from RubyGems. 2007-11-25 03:26:36 +00:00
scanf refine previous change. 2007-09-28 18:22:23 +00:00
sdbm use Dir.mktmpdir. 2007-10-24 06:20:31 +00:00
soap
socket use ML ref. for assertion message. 2007-11-18 07:18:56 +00:00
stringio use ML ref. for assertion message. 2007-11-18 07:18:56 +00:00
strscan * test/socket/test_socket.rb: update not to use 1.8 assignment to 2007-11-14 07:03:39 +00:00
testunit
uri use ML ref. for assertion message. 2007-11-18 07:18:56 +00:00
webrick
win32ole * ext/win32ole/win32ole.c (foletype_s_ole_classes, 2007-10-13 12:40:24 +00:00
wsdl
xmlrpc
xsd
yaml (test_time_now_cycle): cut off under micro second. 2007-12-01 17:24:13 +00:00
zlib use ML ref. for assertion message. 2007-11-18 07:18:56 +00:00
inlinetest.rb
runner.rb
test_generator.rb
test_ipaddr.rb
test_pp.rb
test_prettyprint.rb
test_set.rb
test_shellwords.rb
test_time.rb
test_tsort.rb