[前][次][番号順一覧][スレッド一覧]

ruby-changes:7697

From: akr <ko1@a...>
Date: Sun, 7 Sep 2008 20:03:39 +0900 (JST)
Subject: [ruby-changes:7697] Ruby:r19218 (trunk): * enc/trans/escape.trans (hexstr): renamed from str1.

akr	2008-09-07 20:03:24 +0900 (Sun, 07 Sep 2008)

  New Revision: 19218

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=19218

  Log:
    * enc/trans/escape.trans (hexstr): renamed from str1.

  Modified files:
    trunk/ChangeLog
    trunk/enc/trans/escape.trans

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 19217)
+++ ChangeLog	(revision 19218)
@@ -1,3 +1,7 @@
+Sun Sep  7 20:03:01 2008  Tanaka Akira  <akr@f...>
+
+	* enc/trans/escape.trans (hexstr): renamed from str1.
+
 Sun Sep  7 19:45:31 2008  Tanaka Akira  <akr@f...>
 
 	* enc/trans/escape.trans: use transcode_tblgen.
Index: enc/trans/escape.trans
===================================================================
--- enc/trans/escape.trans	(revision 19217)
+++ enc/trans/escape.trans	(revision 19218)
@@ -1,28 +1,28 @@
 #include "transcode_data.h"
 
 <%
-  def str1(str)
+  def hexstr(str)
     str.unpack("H*")[0]
   end
 
   transcode_tblgen("", "amp-escaped", [
     ["{00-25,27-FF}", :nomap], 
-    ["26", str1("&amp;")]
+    ["26", hexstr("&amp;")]
   ])
 
   transcode_tblgen("", "xml-text-escaped", [
     ["{00-25,27-3B,3D,3F-FF}", :nomap], 
-    ["26", str1("&amp;")],
-    ["3C", str1("&lt;")],
-    ["3E", str1("&gt;")]
+    ["26", hexstr("&amp;")],
+    ["3C", hexstr("&lt;")],
+    ["3E", hexstr("&gt;")]
   ])
 
   transcode_tblgen("", "xml-attr-content-escaped", [
     ["{00-21,23-25,27-3B,3D,3F-FF}", :nomap], 
-    ["22", str1("&quot;")],
-    ["26", str1("&amp;")],
-    ["3C", str1("&lt;")],
-    ["3E", str1("&gt;")]
+    ["22", hexstr("&quot;")],
+    ["26", hexstr("&amp;")],
+    ["3C", hexstr("&lt;")],
+    ["3E", hexstr("&gt;")]
   ])
 
   map_xml_attr_quote = {}

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]