mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
single_byte.trans: dead code
* enc/trans/single_byte.trans (transcode_tblgen_singlebyte): remove useless code. returned value is not used. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56513 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1da2b2e7b9
commit
06711fd1e3
1 changed files with 3 additions and 6 deletions
|
@ -18,15 +18,12 @@
|
|||
# file name: lower case, hyphens, -tbl.rb suffix (e.g. iso-8859-3-tbl.rb)
|
||||
# variable name: UPPER case, underscores, _TO_UCS_TBL suffix (e.g. ISO_8859_3_TO_UCS_TBL)
|
||||
# If the name starts with "ISO-8859", the C1 control code area is added automatically.
|
||||
def transcode_tblgen_singlebyte (name)
|
||||
def transcode_tblgen_singlebyte(name)
|
||||
require(name.downcase + "-tbl")
|
||||
control1_if_needed = (name =~ /^ISO-8859/) ? CONTROL1_TO_UCS_TBL : []
|
||||
tbl_to_ucs = control1_if_needed + eval(name.gsub(/-/, '_') + "_TO_UCS_TBL")
|
||||
code = ''
|
||||
code << transcode_tblgen(name, "UTF-8", [["{00-7f}", :nomap], *tbl_to_ucs.reject {|a, b| a.length != 2 }], '{00-ff}')
|
||||
code << "\n"
|
||||
code << transcode_tblgen("UTF-8", name, [["{00-7f}", :nomap], *tbl_to_ucs.map {|a,b| [b,a] }])
|
||||
code
|
||||
transcode_tblgen(name, "UTF-8", [["{00-7f}", :nomap], *tbl_to_ucs.reject {|a, b| a.length != 2 }], '{00-ff}')
|
||||
transcode_tblgen("UTF-8", name, [["{00-7f}", :nomap], *tbl_to_ucs.map {|a,b| [b,a] }])
|
||||
end
|
||||
|
||||
transcode_tblgen_singlebyte "ISO-8859-1"
|
||||
|
|
Loading…
Reference in a new issue