aboutsummaryrefslogtreecommitdiffstats
path: root/lib/rdoc
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-03-28 03:18:00 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-03-28 03:18:00 +0000
commit12c88c80707bbf136ca5583fe438fb9440e44232 (patch)
treea9b33d1a0169c4a6c370895f72463180b68d3663 /lib/rdoc
parent5880e12d1d40c5d53e00ed5a25063b2c19389668 (diff)
downloadruby-12c88c80707bbf136ca5583fe438fb9440e44232.tar.gz
fix regexp introduced at recent RDoc update (r62924).
* lib/rdoc/text.rb: should escape `-` character. Sometimes test fails if `$VERBOSE = 1` with the following warning: > text.rb:172: warning: character class has duplicated range: ... git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62935 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rdoc')
-rw-r--r--lib/rdoc/text.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rdoc/text.rb b/lib/rdoc/text.rb
index def80d98a3..22c3777ff9 100644
--- a/lib/rdoc/text.rb
+++ b/lib/rdoc/text.rb
@@ -169,7 +169,7 @@ module RDoc::Text
encoding = text.encoding
- text = text.gsub %r%Document-method:\s+[\w:.#=!?|^&<>~+-/*\%@`\[\]]+%, ''
+ text = text.gsub %r%Document-method:\s+[\w:.#=!?|^&<>~+\-/*\%@`\[\]]+%, ''
space = ' '
space = RDoc::Encoding.change_encoding space, encoding if encoding