summaryrefslogtreecommitdiff
path: root/enc/shift_jis.c
AgeCommit message (Collapse)Author
2017-12-01Update to Onigmo 6.1.3-669ac9997619954c298da971fcfacccf36909d05.naruse
[Bug #13892] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60966 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-12-10Merge Onigmo 6.0.0naruse
* https://github.com/k-takata/Onigmo/blob/Onigmo-6.0.0/HISTORY * fix for ruby 2.4: https://github.com/k-takata/Onigmo/pull/78 * suppress warning: https://github.com/k-takata/Onigmo/pull/79 * include/ruby/oniguruma.h: include onigmo.h. * template/encdb.h.tmpl: ignore duplicated definition of EUC-CN in enc/euc_kr.c. It is defined in enc/gb2313.c with CRuby macro. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-07-24* regenc.h/c, include/ruby/oniguruma.h, enc/ascii.c, big5.c, cp949.c,duerst
emacs_mule.c, euc_jp.c, euc_kr.c, euc_tw.c, gb18030.c, gbk.c, iso_8859_1|2|3|4|5|6|7|8|9|10|11|13|14|15|16.c, koi8_r.c, koi8_u.c, shift_jis.c, unicode.c, us_ascii.c, utf_16|32be|le.c, utf_8.c, windows_1250|51|52|53|54|57.c, windows_31j.c, unicode.c: Remove conditional compilation macro ONIG_CASE_MAPPING. [Feature #12386]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55740 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-06-07* regenc.h/c: Rename onigenc_not_support_case_map toduerst
onigenc_ascii_only_case_map. * regenc.h: Add definition of onigenc_single_byte_ascii_only_case_map. * enc/iso_8859_X.c, windows_125X.c, ascii.c, us-ascii.c, koi8_x.c: Replace onigenc_not_support_case_map by onigenc_single_byte_ascii_only_case_map. * enc/big5.c, cp949.c, emacs_mule.c, euc_X.c, gbX.c, shift_jis.c, windows_31j.c: Replace onigenc_not_support_case_map by onigenc_ascii_only_case_map. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-05-22 * include/ruby/oniguruma.h: Extend OnigEncodingTypeDefine to define aduerst
new encoding primitive 'case_map' for case mapping * enc/utf-8.c, utf_16be/le.c, utf_32be/le.c: add onigenc_unicode_case_map as case_map primitive * enc/ascii.c, big5.c, cp949.c, emacs_mule.c, euc_jp/kr/tw.c, gb18030.c, gbk.c, iso_8859_1/2/3/4/5/6/7/8/9/10/11/13/14/15/16.c, koi8_r/u.c, shift_jis.c, us_ascii.c, windows_1250/1251/1252.c: add onigenc_not_support_case_map as case_map primitive git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55113 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-08-27oniguruma.h: constifynobu
* include/ruby/oniguruma.h (OnigEncodingTypeST): constify property_name_to_ctype arguments. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51710 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-09-15* reg*.c: Merge Onigmo 5.15.0 38a870960aa7370051a3544naruse
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47598 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-05-22constify character property tablesnobu
* enc/jis/props.kwd: constify character property tables of JIS based encodings by perfect hash. * enc/euc_jp.c, enc/shift_jis.c: use character property functions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46039 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-01* Merge Onigmo 0fe387da2fee089254f6b04990541c731a26757fnaruse
v5.13.3 [Bug#7972] [Bug#7974] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39547 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-05-20* enc/shift_jis.c (code_to_mbclen): returnnaruse
ONIGERR_INVALID_CODE_POINT_VALUE if the code is invalid. * enc/shift_jis.c (tr_next): increment character until the code is a valid character. [ruby-dev:45652] [Bug #6450] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35724 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-02-17* Merge Onigmo-5.13.1. [ruby-dev:45057] [Feature #5820]naruse
https://github.com/k-takata/Onigmo cp reg{comp,enc,error,exec,parse,syntax}.c reg{enc,int,parse}.h cp oniguruma.h cp tool/enc-unicode.rb cp -r enc/ git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34663 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-02-15Add more description about Shift_JIS and CP50220.naruse
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34623 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-01-08* numeric.c (rb_enc_uint_char): raise RangeError when added codepointnaruse
is invalid. [Feature #5855] [Bug #5863] [Bug #5864] * string.c (rb_str_concat): ditto. * string.c (rb_str_concat): set encoding as ASCII-8BIT when the string is US-ASCII and the argument is an integer greater than 127. * regenc.c (onigenc_mb2_code_to_mbclen): rearrange error code. * enc/euc_jp.c (code_to_mbclen): ditto. * enc/shift_jis.c (code_to_mbclen): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-05-15* remove trailing spaces.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31573 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-03-09* enc/shift_jis.c: Change SJIS as an alias of Windows-31J.naruse
* enc/shift_jis.c: Add PCK as an alias of Windows-31J. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-02-03* enc/shift_jis.c (code_to_mbc): cast as int from the subtraction of pointers.naruse
* enc/utf_16le.c (utf16le_mbc_enc_len): use ptrdiff_t. * enc/utf_32be.c (utf32be_left_adjust_char_head): ditto. * enc/utf_32le.c (utf32le_left_adjust_char_head): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30771 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-11-17* enc/shift_jis.c (property_name_to_ctype): fix memory leak.naruse
* enc/euc_jp.c (property_name_to_ctype): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29810 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-11-09* regenc.c (onigenc_minimum_property_name_to_ctype):naruse
\p{...} should be case insensitive. [ruby-core:33000] * regenc.c (onigenc_property_list_add_property): ditto. * enc/euc_jp.c (init_property_list, property_name_to_ctype): to lowercase property names. * enc/shift_jis.c (init_property_list, property_name_to_ctype): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29732 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-03-01* include/ruby/oniguruma.h: updated to follow Oniguruma 5.9.2.matz
* re.c (make_regexp): use onig_new() instead of onig_alloc_init(). * re.c (rb_reg_to_s): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26791 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-09-18* grapheme cluster implementation reverted. [ruby-dev:36375]akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19417 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-09-16* include/ruby/oniguruma.h (OnigEncodingTypeST): add precise_retakr
argument for mbc_to_code. (ONIGENC_MBC_TO_CODE): provide NULL for precise_ret. (ONIGENC_MBC_PRECISE_CODEPOINT): defined. * include/ruby/encoding.h (rb_enc_mbc_precise_codepoint): defined. * regenc.h (onigenc_single_byte_mbc_to_code): precise_ret argument added. (onigenc_mbn_mbc_to_code): ditto. * regenc.c (onigenc_single_byte_mbc_to_code): precise_ret argument added. (onigenc_mbn_mbc_to_code): ditto. * string.c (count_utf8_lead_bytes_with_word): removed. (str_utf8_nth): removed. (str_utf8_offset): removed. (str_strlen): UTF-8 codepoint oriented optimization removed. (rb_str_substr): ditto. (enc_succ_char): use rb_enc_mbc_precise_codepoint. (enc_pred_char): ditto. (rb_str_succ): ditto. * encoding.c (rb_enc_ascget): check length with rb_enc_mbc_precise_codepoint. (rb_enc_codepoint): use rb_enc_mbc_precise_codepoint. * regexec.c (string_cmp_ic): add text_end argument. (match_at): check end of character after exact string matches. * enc/utf_8.c (graphme_table): defined for extended graphme cluster boundary. (grapheme_cmp): defined. (get_grapheme_properties): defined. (grapheme_boundary_p): defined. (MAX_BYTES_LENGTH): defined. (comb_char_enc_len): defined. (mbc_to_code0): extracted from mbc_to_code. (mbc_to_code): use mbc_to_code0. (left_adjust_combchar_head): defined. (utf_8): use a extended graphme cluster as a unit. * enc/unicode.c (onigenc_unicode_mbc_case_fold): use ONIGENC_MBC_PRECISE_CODEPOINT to extract codepoints. (onigenc_unicode_get_case_fold_codes_by_str): ditto. * enc/euc_jp.c (mbc_to_code): follow mbc_to_code field change. use onigenc_mbn_mbc_to_code. * enc/shift_jis.c (mbc_to_code): ditto. * enc/emacs_mule.c (mbc_to_code): ditto. * enc/gbk.c (gbk_mbc_to_code): follow mbc_to_code field and onigenc_mbn_mbc_to_code change. * enc/cp949.c (cp949_mbc_to_code): ditto. * enc/big5.c (big5_mbc_to_code): ditto. * enc/euc_tw.c (euctw_mbc_to_code): ditto. * enc/euc_kr.c (euckr_mbc_to_code): ditto. * enc/gb18030.c (gb18030_mbc_to_code): ditto. * enc/utf_32be.c (utf32be_mbc_to_code): follow mbc_to_code field change. * enc/utf_16be.c (utf16be_mbc_to_code): ditto. * enc/utf_32le.c (utf32le_mbc_to_code): ditto. * enc/utf_16le.c (utf16le_mbc_to_code): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19389 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-09-13* include/ruby/oniguruma.h (OnigEncodingTypeST): add end argument forakr
left_adjust_char_head. (ONIGENC_LEFT_ADJUST_CHAR_HEAD): add end argument. (onigenc_get_left_adjust_char_head): ditto. * include/ruby/encoding.h (rb_enc_left_char_head): add end argument. * regenc.h (onigenc_single_byte_left_adjust_char_head): ditto. * regenc.c (onigenc_get_right_adjust_char_head): follow the interface change. (onigenc_get_right_adjust_char_head_with_prev): ditto. (onigenc_get_prev_char_head): ditto. (onigenc_step_back): ditto. (onigenc_get_left_adjust_char_head): ditto. (onigenc_single_byte_code_to_mbc): ditto. * re.c: ditto. * string.c: ditto. * io.c: ditto. * regexec.c: ditto. * enc/euc_jp.c: ditto. * enc/cp949.c: ditto. * enc/shift_jis.c: ditto. * enc/gbk.c: ditto. * enc/big5.c: ditto. * enc/euc_tw.c: ditto. * enc/euc_kr.c: ditto. * enc/emacs_mule.c: ditto. * enc/gb18030.c: ditto. * enc/utf_8.c: ditto. * enc/utf_16le.c: ditto. * enc/utf_16be.c: ditto. * enc/utf_32le.c: ditto. * enc/utf_32be.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19334 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-01* enc/shift_jis.c (code_is_ctype): HALF WIDTH KATAKANA isnaruse
a character. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-01forgot to commitshyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-17* enc/euc_jp.c (property_name_to_ctype): core dumped when sizeof(int)mame
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-02-17* enc/{euc_jp.c,gbk.c,iso_8859_1.c,iso_8859_11.c,iso_8859_13.c,naruse
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-01-17* enc/shift_jis.c: newline at EOF.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-15* enc/*: add ARG_UNUSED.naruse
* 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* encoding.c (ENC_REGISTER): use &OnigEncoding*.naruse
(ENCINDEX_UTF_8): renamed from ENCINDEX_UTF8. (rb_enc_init): use ENC_REGISTER. * include/ruby/oniguruma.h (OnigEncodingUTF8, ONIG_ENCODING_UTF8): removed. * enc/*.c: remove use of &encoding_*; use enc argument instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-13* enc/*.c: add replicas and aliases.naruse
* enc/make_encdb.h: add duplicate and undefined check. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15028 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-13* include/ruby/oniguruma.h: remove ONIG_ENCODING_* and OnigEncoding*naruse
which are not builtin. * regenc.{c,h} (onigenc_mb2_code_to_mbclen, onigenc_mb4_code_to_mbclen): fix prototype. * enc/big5.c, enc/euc_kr.c, enc/euc_tw.c, enc/gb18030.c, enc/koi8_r.c, enc/windows_1251.c: imported from Oniguruma. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15026 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-13* encoding.c (ENCINDEX_EUC_JP, ENCINDEX_SJIS): removed.naruse
(rb_enc_init): EUC-JP and Shift_JIS are not builtin now. * enc/Makefile.in: ditto. * common.mk: ditto. * ruby.c (proc_options): ditto. * enc/shift_jis.c, enc/euc_jp.c: fixes for romove from builtin. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15016 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-13* encoding.c (rb_enc_init): revert removing SJIS.naruse
* enc/sjis.c: move to enc/shift_jis.c, to make encoding name equal to filename for convinience of loading lib. * enc/shift_jis.c: moved from enc/sjis.c. * common.mk: follows enc/shift_jis.c. * enc/Makefile.in: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15014 b2dd03c8-39d4-4d8f-98ff-823fe69b080e