akr
279e612973
fix variable name.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18558 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-13 05:53:20 +00:00
akr
a14d5eb09b
* enc/trans/newline.trans (rb_crlf_newline): new transcoder.
...
(rb_cr_newline): new transcoder.
* transcode.c (trans_open_i): one more exra room for input newline
converter.
(rb_trans_open): crlf newline and cr newline implemented.
(Init_transcode): Encoding::Converter::CRLF_NEWLINE and
Encoding::Converter::LF_NEWLINE defined.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-13 05:48:57 +00:00
akr
74a2a7bdbf
* enc/trans/newline.trans: new file.
...
* transcode_data.h (rb_trans_t): add last_tc field.
* transcode.c (UNIVERSAL_NEWLINE): defined.
(CRLF_NEWLINE): defined.
(CR_NEWLINE): defined.
(rb_trans_open_by_transcoder_entries): initialize last_tc.
(trans_open_i): allocate one more room for newline converter.
(rb_trans_open): universal newline implemented.
(more_output_buffer): take max_output argument instead ts.
(output_replacement_character): take tc argument instead of ts.
(transcode_loop): use last_tc field.
(econv_init): add flags argument for rb_trans_open.
(Init_transcode): Encoding::Converter::UNIVERSAL_NEWLINE defined.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18556 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-13 05:30:42 +00:00
akr
79cd32fe3b
* enc/trans/make_transdb.rb: *.erb.c is not used anymore.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18532 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-12 09:43:44 +00:00
usa
6d8c1483d6
* enc/depend: (transvpath_prefix): prefix has no extension, so replace
...
%s with "".
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18517 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-12 06:19:00 +00:00
nobu
13f1418d54
* enc/Makefile.in (.SUFFIXES): renamed to .trans.
...
* enc/make_encmake.rb: added --encs and --no-encs options.
* enc/depend (TRANSVPATH): fix for nmake.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18513 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-12 05:25:14 +00:00
akr
94ca2d94de
* transcode_data.h (rb_transcoder): add resetstate_func field for
...
resetting a state of stateful encoding.
* enc/trans/iso2022.trans (rb_EUC_JP_to_ISO_2022_JP): specify
finish_eucjp_to_iso2022jp for resetstate_func.
* tool/transcode-tblgen.rb: specify NULL for resetstate_func.
* transcode.c (output_replacement_character): call resetstate_func
before appending the replacement character.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18503 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-11 22:44:23 +00:00
akr
2897632f16
* enc/trans/iso2022.trans: renamed from iso2022.erb.c.
...
* enc/trans/single_byte.trans: ditto.
* enc/trans/utf_16_32.trans: ditto.
* enc/trans/korean.trans: ditto.
* enc/trans/japanese.trans: ditto.
* enc/depend: follow the renaming.
* tool/build-transcode: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18488 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-11 07:39:52 +00:00
nobu
e3d9fc76e6
* enc/Makefile.in (make-workdir): use MAKEDIRS.
...
* enc/depend: makes target directory before compile/link.
* tool/transcode-tblgen.rb: creates target directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18469 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-10 02:45:18 +00:00
akr
139234e1a0
* transcode_data.h (rb_transcoding): add fields for restartable
...
transcoding.
(rb_transcoder): add max_input field.
from_unit_length field is renamed to input_unit_length.
* tool/transcode-tblgen.rb: generate max_input field.
* enc/trans/iso2022.erb.c: follow rb_transcoder change.
* enc/trans/utf_16_32.erb.c: ditto.
* transcode.c (PARTIAL_INPUT): new constant.
(transcode_char_start): new function.
(transcode_result_t): new type.
(transcode_restartable): new function.
(more_output_buffer): new function.
(transcode_loop): use transcode_restartable.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18452 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-09 06:02:01 +00:00
nobu
1727355a22
* enc/make_encdb.rb, enc/trans/make_transdb.rb: skip nonexistent
...
directory. [ruby-dev:35802]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 21:37:43 +00:00
akr
6db9e77e64
* enc/trans/utf_16_32.erb.c (fun_so_from_utf_32le): implemented.
...
(fun_so_to_utf_32le): implemented.
[ruby-dev:35777]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18447 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 16:08:50 +00:00
akr
2833d9f95d
* transcode_data.h (rb_transcoder): from_unit_length field added.
...
from_utf8 field removed.
* tool/transcode-tblgen.rb: generate offsets range.
follow rb_transcoder change.
* transcode.c (transcode_loop): don't use from_utf8.
make invalid region from_unit_length wise.
* enc/trans/iso2022.erb.c: follow rb_transcoder and
transcode_generate_node change.
* enc/trans/utf_16_32.erb.c: follow rb_transcoder and
transcode_generate_node change.
explicit :invalid map removed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18445 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 15:48:17 +00:00
nobu
a456f022fc
* enc/depend (TRANSCSRCS): needs rule_subst to apply.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18444 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 14:30:05 +00:00
nobu
2293171034
* common.mk (srcs-enc): renamed from transcodes.
...
* enc/Makefile.in (make-workdir): creates object directories.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18437 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 07:44:42 +00:00
nobu
b917553e68
* common.mk (encdb.h): see both $(srcdir)/enc and enc.
...
* enc/make_encdb.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18435 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 07:15:52 +00:00
nobu
2f37e03736
* enc/trans/make_transdb.rb: fix for the case no transdirs are given.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18434 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 07:09:03 +00:00
nobu
73d3ff0074
* enc/trans/make_transdb.rb: converts only one transcoders for each
...
basename.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-08 07:03:35 +00:00
naruse
b41a687fe6
* common.mk: see both $(srcdir)/enc/trans and enc/trans.
...
* enc/trans/make_transdb.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18422 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-07 19:24:47 +00:00
akr
1504652373
* transcode_data.h (rb_transcoding): new field "stateful".
...
(rb_transcoder): preprocessor and postprocessor field removed.
change arguments of func_ii, func_si, func_io and func_so.
new field "finish_func".
* tool/transcode-tblgen.rb: make FUNii, FUNsi and FUNio
generatable.
* transcode.c (transcoder_lib_table): removed.
(transcoder_table): change structure.
(transcoder_key): removed because the above structure change.
(make_transcoder_entry): new function.
(get_transcoder_entry): ditto.
(rb_register_transcoder): follow the structure change.
(declare_transcoder): ditto.
(transcode_search_path): new function for breadth first search to
find a list of converters.
(transcode_search_path_i): new function.
(transcode_dispatch_cb): ditto.
(transcode_dispatch): use transcode_search_path.
(transcode_loop): follow the argument change.
(str_transcode): preprocessor and postprocessor stuff removed.
* enc/trans/iso2022.erb.c: new file. ISO-2022-JP conversion
re-implemented.
* enc/trans/japanese.erb.c: ISO-2022-JP stuff removed.
nute(23:52:53)% head -40 ChangeLog
Thu Aug 7 23:43:11 2008 Tanaka Akira <akr@fsij.org>
* transcode_data.h (rb_transcoding): new field "stateful".
(rb_transcoder): preprocessor and postprocessor field removed.
change arguments of func_ii, func_si, func_io and func_so.
new field "finish_func".
* tool/transcode-tblgen.rb: make FUNii, FUNsi and FUNio
generatable.
* transcode.c (transcoder_lib_table): removed.
(transcoder_table): change structure.
(transcoder_key): removed because the above structure change.
(make_transcoder_entry): new function.
(get_transcoder_entry): ditto.
(rb_register_transcoder): follow the structure change.
(declare_transcoder): ditto.
(transcode_search_path): new function for breadth first search to
find a list of converters.
(transcode_search_path_i): new function.
(transcode_dispatch_cb): ditto.
(transcode_dispatch): use transcode_search_path.
(transcode_loop): follow the argument change.
(str_transcode): preprocessor and postprocessor stuff removed.
* enc/trans/iso2022.erb.c: new file. ISO-2022-JP conversion
re-implemented.
* enc/trans/japanese.erb.c: ISO-2022-JP stuff removed.
* enc/trans/utf_16_32.erb.c: follow argument change of FUNso.
[ruby-dev:35798]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18419 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-07 14:53:30 +00:00
nobu
380e558f33
* enc/depend: add transdb.c.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18412 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-07 08:47:58 +00:00
nobu
fa3283c7ba
* enc/depend: removed needless explicit commands.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18410 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-07 05:17:34 +00:00
naruse
ec85af4955
* enc/depend: enc/*.c is source but enc/trans/*.c is generated.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18400 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 20:19:25 +00:00
naruse
508b170dcd
* enc/depend: for build in other than srcdir.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18396 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 19:44:50 +00:00
akr
e22b3b773d
* tool/transcode-tblgen.rb (transcode_generate_node): code
...
argument removed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18395 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 13:42:21 +00:00
akr
a016b30844
* enc/depend: transcode table generation depends on
...
tool/transcode-tblgen.rb.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18393 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 11:57:32 +00:00
akr
fc841ddc66
useless comment removed.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18389 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 11:44:08 +00:00
nobu
8db17b30d6
* common.mk (transdb.h): requires transcoders.
...
* enc/depend (srcs): target for transcoders.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18387 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 05:40:13 +00:00
usa
ce074dcf42
* enc/depend: replace not only $(<:...) but also $<.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18386 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 05:04:36 +00:00
usa
19e2cdbd47
* win32/Makefile.sub (config.status): export BASERUBY.
...
* enc/depend: avoid GNU make'ism.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18384 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06 04:55:39 +00:00
akr
e90dd02529
* tool/transcode-tblgen.rb: show generating tables in verbose mode.
...
(transcode_generate_node): call ActionMap#generate_node with showing
table name.
* enc/trans/utf_16_32.erb.c: use transcode_generate_node.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18382 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-05 22:47:44 +00:00
nobu
0031e09170
* common.mk (transcodes), tool/build-transcode: generates transcode
...
sources.
* enc/trans/{japanese,korean,single_byte,utf_16_32}.c: to be
autogenerated now.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18376 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-05 18:56:42 +00:00
nobu
82e89f1237
* enc/depend: added rules for .c from .erb.c.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18374 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-05 18:15:52 +00:00
akr
f694ec83e8
* tool/build-transcode: new file.
...
* tool/transcode-tblgen.rb: new file.
* enc/trans/make_transdb.rb: exclude *.erb.c.
* enc/depend: exclude *.erb.c.
* enc/trans/utf_16_32.erb.c: new file.
* enc/trans/single_byte.erb.c: new file.
* enc/trans/japanese.erb.c: new file.
* enc/trans/korean.erb.c: new file.
* enc/trans/iso-8859-2-tbl.rb: new file.
* enc/trans/iso-8859-3-tbl.rb: new file.
* enc/trans/iso-8859-4-tbl.rb: new file.
* enc/trans/iso-8859-5-tbl.rb: new file.
* enc/trans/iso-8859-6-tbl.rb: new file.
* enc/trans/iso-8859-7-tbl.rb: new file.
* enc/trans/iso-8859-8-tbl.rb: new file.
* enc/trans/iso-8859-9-tbl.rb: new file.
* enc/trans/iso-8859-10-tbl.rb: new file.
* enc/trans/iso-8859-11-tbl.rb: new file.
* enc/trans/iso-8859-13-tbl.rb: new file.
* enc/trans/iso-8859-14-tbl.rb: new file.
* enc/trans/iso-8859-15-tbl.rb: new file.
* enc/trans/eucjp-tbl.rb: new file.
* enc/trans/sjis-tbl.rb: new file.
* enc/trans/euckr-tbl.rb: new file.
* enc/trans/utf_16_32.c: regenerated.
* enc/trans/single_byte.c: regenerated.
* enc/trans/japanese.c: regenerated.
* enc/trans/korean.c: regenerated.
[ruby-dev:35730]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18373 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-05 12:32:13 +00:00
nobu
b84d31c524
* transcode_data.h (TRANSCODE_ERROR): common transcode failure
...
exception, would be changed later.
* enc/trans/japanese.c (UNSUPPORTED_MODE): unsupported mode transition
exception.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18363 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-05 03:34:52 +00:00
naruse
4de6475690
* enc/trans/japanese.c: add U+FF5E to EUC-JP.
...
[ruby-dev:35720] [ruby-dev:35722]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18315 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-01 16:26:23 +00:00
naruse
4fc3ef70e1
* enc/trans/japanese.c: add support for CP51932,
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18310 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-01 14:17:21 +00:00
naruse
35bac2083c
* enc/trans/japanese.c: add U+FF0C,
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-01 14:03:14 +00:00
naruse
143b3339e6
* enc/trans/japanese.c (to_SHIFT_JIS_EF_BF_offsets): add U+FFF3,
...
U+FFF4, U+FFF5.
* enc/trans/japanese.c (to_SHIFT_JIS_EF_BF_infos): ditto.
* enc/trans/japanese.c (to_EUC_JP_EF_BF_infos): added.
* enc/trans/japanese.c (to_EUC_JP_EF_BF): added.
* enc/trans/japanese.c (to_EUC_JP_EF_infos): change size.
[ruby-dev:35714]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-01 12:26:56 +00:00
nobu
94ed51b281
* transcode.c (transcode_loop): constified.
...
* transcode.c (str_transcode): rb_str_set_len() sets a delimiter.
* transcode_data.h (rb_transcoder): constified preprocessor and
postprocessor input.
* enc/trans/japanese.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18066 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-14 09:47:33 +00:00
naruse
5b7dfb7c13
* enc/shift_jis.c (code_is_ctype): HALF WIDTH KATAKANA is
...
a character.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-01 10:05:48 +00:00
shyouhei
0ef21e44e7
forgot to commit
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-01 09:50:30 +00:00
usa
40612c5bb5
* enc/make_encdb.h: always add ';' at the end of line.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17771 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-01 08:51:33 +00:00
shyouhei
53cffba8cb
* enc/ascii.c: ISO C does not allow extra ';' outside of a
...
function
* enc/us_ascii.c: ditto.
* enc/utf_8.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17768 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-01 08:39:10 +00:00
mame
d7baa40cac
* enc/euc_jp.c (property_name_to_ctype): core dumped when sizeof(int)
...
differs from sizeof(long).
* enc/shift_jis.c (property_name_to_ctype): ditto.
* enc/unicode.c (onigenc_unicode_property_name_to_ctype): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17381 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-17 13:06:34 +00:00
nobu
fc0babb4c2
* enc/depend (clean): remove build directories.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17060 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-09 12:17:29 +00:00
nobu
ce29c17877
* lib/mkmf.rb (configuration): set flags.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17058 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-09 12:14:39 +00:00
mame
65670f9400
* enc/iso_8859_5.c: Large omicron should lowercase to small omicron.
...
* test/ruby/test_big5.rb, test/ruby/test_cp949.rb,
test/ruby/test_euc_jp.rb, test/ruby/test_euc_kr.rb,
test/ruby/test_euc_tw.rb, test/ruby/test_gb18030.rb,
test/ruby/test_gbk.rb, test/ruby/test_iso_8859.rb,
test/ruby/test_koi8.rb, test/ruby/test_shift_jis.rb,
test/ruby/test_windows_1251.rb: new tests for encoding.
* test/ruby/test_utf16.rb, test/ruby/test_utf32.rb,
test/ruby/test_regexp.rb: add tests.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-02 13:30:38 +00:00
naruse
5397015d2e
* enc/gb18030.c (gb18030_code_to_mbc): add 0x80000000
...
for 4bytes character.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16739 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-01 19:36:28 +00:00
naruse
9c13fc7d89
* enc/gb18030.c (gb18030_mbc_to_code): mask by 0x7FFFFFFF
...
because OnigCodePoint will be used as 32bit signed int.
Masking by 0x7FFFFFFF is ok on GB18030;
Minumum 4bytes character is 0x81308130.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16737 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-01 18:29:08 +00:00
naruse
0682fab6a2
* enc/utf_16{be,le}.c (utf16{be,le}_code_to_mbc):
...
fix codepoint to bytes.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16717 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-31 10:14:38 +00:00
nobu
6a734c810c
* common.mk (prelude.c): simply depends on PREP. [ruby-dev:34877]
...
* enc/make_encdb.rb, enc/trans/make_transdb.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16703 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-30 03:18:45 +00:00
naruse
d6025a3be4
* enc/utf_8.c: add UTF8-MAC (UTF-8-MAC).
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16697 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-29 22:12:57 +00:00
usa
22088e3423
* enc/trans/japanese.c (to_SHIFT_JIS_EF_infos): typo.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16661 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-28 06:54:18 +00:00
naruse
3ab17047f5
* enc/trans/japanese.c: add workarround for Unicode to CP932.
...
U+2015->0x815C, U+2225->0x8161, U+FF0D->0x817C, U+FF3C->0x815F,
U+FF5E->0x8160, U+FFE0->0x8191, U+FFE1->0x8192, U+FFE2->0x81CA
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16657 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-28 04:35:59 +00:00
mame
0a2053713b
* enc/trans/utf_16_32.c (fun_so_to_utf_16be, fun_so_to_utf_16le): add
...
parentheses to remove warnings of gcc.
* io.c (rb_io_getc): remove unused variables.
* compile.c (NODE_NEXT, NODE_REDO): remove unused labels.
* ext/nkf/nkf.c (rb_nkf_convert): remove unused variables.
* ext/syck/rubyext.c (syck_resolver_initialize,
syck_resolver_detect_implicit, syck_emitter_emit): remove unused
variables.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-04-17 13:22:40 +00:00
nobu
7dc26509c6
* common.mk (prelude.c): depends on enc/prelude.rb.
...
* enc/prelude.rb: fixed initial library names.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15922 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-04-08 01:30:31 +00:00
nobu
1369cfd16e
* encoding.c (enc_init_db): moved to enc/encdb.c.
...
* transcode.c (init_transcoder_table): moved to enc/trans/transdb.c.
* enc/depend (enc/encdb.o enc/trans/transdb.o): depend on
corresponding headers.
* common.mk (COMMONOBJS): moved transcode.o from OBJS
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15915 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-04-07 06:51:33 +00:00
duerst
2e7815dd80
Sun Mar 16 18:07:07 2008 Martin Duerst <duerst@it.aoyama.ac.jp>
...
* enc/trans/utf_16_32.c: bug fix (some invalid UTF-8 sequences
were legal)
* test/ruby/test_transcode.rb: test for above bug
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15786 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-16 09:09:53 +00:00
nobu
9d014dc254
* ext/extmk.rb, enc/make_encmake.rb: load current mkmf.rb even if
...
cross-compiling.
* ext/extmk.rb, enc/make_encmake.rb, lib/mkmf.rb: need to be 1.8
compatible for cross-compiling.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15616 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-26 18:56:00 +00:00
nobu
80e81d283d
* enc/{depend,make_encdb.rb,trans/make_transdb.rb}: sort in alpha-numeric order.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15567 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-22 00:07:23 +00:00
naruse
8984fa6742
* enc/{euc_jp.c,gbk.c,iso_8859_1.c,iso_8859_11.c,iso_8859_13.c,
...
iso_8859_2.c,iso_8859_6.c,iso_8859_7.c,iso_8859_8.c,iso_8859_9.c,
shift_jis.c,windows_1251.c}: add document about encodings.
* enc/cp949.c: divided into new file.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15516 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-17 03:21:20 +00:00
naruse
a2d85d61bd
* enc/iso_8859_{4,13}.c: Windows-1257 is replica of ISO-8859-13.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15495 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-15 20:55:27 +00:00
naruse
a8739621cf
* lib/uri/generic.rb: revert r15442. 2nd argument of String#sub parse
...
escapes. [ruby-dev:33726]
* bootstraptest/test_method.rb enc/depend instruby.rb lib/mkmf.rb
mkconfig.rb: revert r15443. ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15456 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-13 07:26:52 +00:00
usa
f6628871b5
* enc/depend: fix typo.
...
* lib/mkmf.rb: revert r15443. "\\1#{sep}\\2" is wrong if sep is ended
with "\\".
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15455 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-13 02:21:25 +00:00
naruse
a10ded3ba0
* bootstraptest/runner.rb, bootstraptest/test_method.rb, enc/depend,
...
instruby.rb, lib/mkmf.rb, lib/test/unit/util/procwrapper.rb,
mkconfig.rb, sample/test.rb, template/vm.inc.tmpl,
test/ruby/test_stringchar.rb: fixes arround String#gsub.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15443 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-12 06:28:23 +00:00
naruse
e22ff0c9b6
* enc/trans/korean.c: add support for CP949 by Park Ji-In. [ruby-dev:33626]
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15393 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-07 06:05:32 +00:00
naruse
4f0083e45f
* enc/trans/korean.c: add EUC-KR conversion support by Park Ji-In.
...
[ruby-dev:33621]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15385 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-02-06 19:40:11 +00:00
naruse
9ac5a0ca4d
* enc/*.c: add GB12345, UCS-{2,4}{BE,LE}.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15341 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-30 08:35:03 +00:00
akr
44cfd58dc5
* enc/utf_16be.c (UTF16_IS_SURROGATE_FIRST): avoid branch.
...
(UTF16_IS_SURROGATE_SECOND): ditto.
(UTF16_IS_SURROGATE): defined.
(utf16be_mbc_enc_len): validation implemented.
* enc/utf_16le.c (UTF16_IS_SURROGATE_FIRST): avoid branch.
(UTF16_IS_SURROGATE_SECOND): ditto.
(UTF16_IS_SURROGATE): defined.
(utf16le_mbc_enc_len): validation implemented.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15338 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-30 03:49:54 +00:00
akr
0ba09d829c
fix state definition.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 15:35:37 +00:00
akr
12e8b588ac
* enc/euc_tw.c (euctw_mbc_enc_len): validation implemented.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15331 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 15:10:50 +00:00
akr
6e3391c866
* enc/euc_tw.c (euctw_islead): 0x8e is a leading byte.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15323 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 13:01:27 +00:00
naruse
b9821b02a0
* enc/trans/make_transdb.rb: add for make transdb.h.
...
* dmytranscode.c: add for miniruby.
* enc/gbk.c (gbk_left_adjust_char_head, gbk_is_allowed_reverse_match):
fix odd regexp match. [ruby-dev:33502]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 11:44:08 +00:00
naruse
7a8c02cd47
* add enc/trans/make_transdb.rb, dmytranscode.c
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 11:18:22 +00:00
naruse
74b254e833
* enc/trans/japanese.c (rb_to_Windows_31J): to 'Windows-31J'.
...
* common.mk: add rules for transdb.h.
* transcode.c (init_transcoder_table): use transdb.h.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 10:05:39 +00:00
naruse
19d9380b3d
* enc/gbk.c (EncLen_gbk): too short. [ruby-dev:33497]
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15315 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 08:55:19 +00:00
akr
86a9215bbf
* enc/gb18030.c (gb18030_mbc_enc_len): validation implemented.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15313 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 08:38:21 +00:00
naruse
00a3c40c37
* enc/euc_kr.c: remove CP949.
...
* enc/euc_cn.c: remove CP936 and rename to gb2312.c
* enc/gb2312.c: GB2312 is preferred MIME name.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 04:41:41 +00:00
naruse
fe15b86b9d
* enc/gbk.c: add GBK, CP936 and CP949.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15308 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 04:26:30 +00:00
naruse
a2b03f10dc
* enc/gbk.c: add GBK, CP936 and CP949.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-29 03:55:45 +00:00
naruse
2f961c1f37
* enc/utf_7.h: add dummy encoding UTF-7 and its alias CP65000.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15291 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-28 08:57:40 +00:00
usa
fee57bb8c8
* enc/utf_8.c: add alias CP65001.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15290 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-28 08:41:49 +00:00
akr
ffbf8ab367
* enc/big5.c (big5_mbc_enc_len): validation implemented.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15289 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-28 06:33:57 +00:00
akr
5f9bc1779e
* enc/euc_kr.c (euckr_mbc_enc_len): validation implemented.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15288 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-28 04:02:39 +00:00
nobu
b2c5814afc
* enc/trans/japanese.c (rb_from_Windows_31J, rb_to_Windows_31J):
...
provisional workaround for Windows-31J. [ruby-dev:33320]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15188 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-23 13:14:31 +00:00
duerst
ef3fdbca15
Tue Jan 22 17:52:52 2008 Martin Duerst <duerst@it.aoyama.ac.jp>
...
* enc/trans/utf_16_32.c: Streamline parentheses, add more
'static' qualifiers.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-22 08:52:02 +00:00
duerst
38321fc0eb
Mon Jan 21 19:42:42 2008 Martin Duerst <duerst@it.aoyama.ac.jp>
...
* transcode.c, enc/trans/utf_16_32.c, test/ruby/test_transcode.rb:
added UTF-32BE and UTF-32LE conversions.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-21 10:41:59 +00:00
nobu
463af63468
* transcode.c (transcode_loop, str_transcoding_resize): use unsigned
...
char. [ruby-dev:33232]
* transcode_data.h (rb_transcoding, rb_transcoder): removed callback
parameters.
* enc/trans/japanese.c: ditto.
* enc/trans/utf_16_32.c: parenthesized bit-or operands.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-21 03:35:05 +00:00
nobu
a8969e999a
* transcode.c (transcode_dispatch): constified return value.
...
* transcode_data.h (rb_transcoding): include pointer to rb_transcoder
and auxiliary data.
* transcode_data.h (rb_transcoder): all callback functions shoud have
their own parameters.
* enc/trans/{japanese,single_byte}.c: constified.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-20 21:40:08 +00:00
duerst
a9b15a4e0c
Sun Jan 20 20:00:20 2008 Martin Duerst <duerst@it.aoyama.ac.jp>
...
* transcode.c, enc/trans/utf_16_32.c, test/ruby/test_transcode.rb:
added UTF-16LE conversions.
* fixed changelog for last commit
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15144 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-20 11:00:24 +00:00
duerst
3d0c7bea4d
Sun Jan 20 15:08:08 2008 Martin Duerst <duerst@it.aoyama.ac.jp>
...
* enc/trans/utf_16_32.c: new file, currently implementing
UTF-16BE conversions only.
* test/ruby/test_transcode.rb: Added tests for UTF-16BE;
made check_both_ways() use force_encoding differently.
* transcode_data.h, transcode.c: Support for more conversion
functions.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-20 06:12:48 +00:00
naruse
9a1d7e4d01
* enc/make_encdb.rb: fix duplication check.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15135 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-19 20:15:13 +00:00
naruse
7b3781c60c
* ascii.c: remove difinition of replica KOI8-U.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15134 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-19 20:04:35 +00:00
naruse
6e1c3a0f54
* enc/koi8_u.c: added.
...
* regenc.c, enc/utf_8.c, enc/unicode.c, enc/gb18030.c: add ARG_UNUSED.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-19 15:37:06 +00:00
nobu
8b112c580c
* enc/euc_cn.c: split from enc/euc_kr.c.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-17 15:17:21 +00:00
nobu
0052259d5e
* common.mk (encdb.h): give output file name to make_encdb.rb.
...
* encoding.c (enc_table): simplified.
* encoding.c (enc_register_at): lazy loading. [ruby-dev:33013]
* regenc.h (ENC_DUMMY): added.
* enc/make_encdb.rb: now emits macros only.
* enc/iso_2022_jp.h: split from encoding.c.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15086 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-17 14:56:22 +00:00
nobu
85e6dff165
* enc/shift_jis.c: newline at EOF.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-17 08:08:08 +00:00
nobu
9c1bf098e0
* enc/windows_1251.c: newline at EOF.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-16 09:38:01 +00:00
naruse
0a640a9386
* enc/*: add ARG_UNUSED.
...
* enc/koi8_u.c: added.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15069 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-15 14:54:40 +00:00