summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--sample/exyacc.rb4
2 files changed, 6 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index b66080cbde..49fc41556a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Sun Apr 6 00:35:37 2003 Tanaka Akira <akr@m17n.org>
+
+ * sample/exyacc.rb: use Regexp in gsub!.
+
Fri Apr 4 10:53:22 2003 Yukihiro Matsumoto <matz@ruby-lang.org>
* eval.c (assign): should prepare mrhs by svalue_to_mrhs().
diff --git a/sample/exyacc.rb b/sample/exyacc.rb
index 908ba6c501..b8d49d630a 100644
--- a/sample/exyacc.rb
+++ b/sample/exyacc.rb
@@ -11,8 +11,8 @@ while gets()
sub!(/.*\n/, "")
gsub!(/'\{'/, "'\001'")
gsub!(/'}'/, "'\002'")
- gsub!('\*/', "\003\003")
- gsub!("/\\*[^\003]*\003\003", '')
+ gsub!(%r{\*/}, "\003\003")
+ gsub!(%r{/\*[^\003]*\003\003}, '')
while gsub!(/\{[^{}]*}/, ''); end
gsub!(/'\001'/, "'{'")
gsub!(/'\002'/, "'}'")