summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-04-26 13:25:09 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-04-26 13:25:09 +0000
commitb6285a01fb49551e85c20587f6f9846a55f32bf5 (patch)
treeffa466f109290de98efa81e3b2603f901fd44eaf
parent0881a39acd7d3dfa6cdbea76f80dabd939996807 (diff)
* tool/transcode-tb (ActionMap#each_firstbyte):
if :asis collides other mappings, use another. * tool/transcode-tb (ActionMap#generate_info): add :asis for ASIS. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23295 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog8
-rw-r--r--tool/transcode-tblgen.rb7
2 files changed, 14 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 796b36c37bf..9eb1dcda4fd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+Sun Apr 26 22:17:02 2009 NARUSE, Yui <naruse@ruby-lang.org>
+
+ * tool/transcode-tb (ActionMap#each_firstbyte):
+ if :asis collides other mappings, use another.
+
+ * tool/transcode-tb (ActionMap#generate_info):
+ add :asis for ASIS.
+
Sun Apr 26 21:59:43 2009 NARUSE, Yui <naruse@ruby-lang.org>
* transcode.c (ASIS): added for multi byte direct map.
diff --git a/tool/transcode-tblgen.rb b/tool/transcode-tblgen.rb
index 266b5a85004..83fc198da04 100644
--- a/tool/transcode-tblgen.rb
+++ b/tool/transcode-tblgen.rb
@@ -237,7 +237,10 @@ class ActionMap
else
ss.each_firstbyte {|byte, rest|
h[byte] ||= {}
- if h[byte][rest]
+ if h[byte][rest].nil?
+ elsif action == :asis
+ next
+ elsif h[byte][rest] != :asis
raise "ambiguous %s or %s (%02X/%s)" % [h[byte][rest], action, byte, rest]
end
h[byte][rest] = action
@@ -316,6 +319,8 @@ class ActionMap
case info
when :nomap
"NOMAP"
+ when :asis
+ "ASIS"
when :undef
"UNDEF"
when :invalid