1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/optparse.rb (OptionParser#compsys): escape brackets too.

[ruby-dev:42754]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30394 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
kazu 2010-12-26 23:30:33 +00:00
parent 2ea38fdd27
commit 0924e52c24
2 changed files with 6 additions and 1 deletions

View file

@ -1,3 +1,8 @@
Mon Dec 27 07:32:07 2010 Kazuhiro NISHIYAMA <zn@mbf.nifty.com>
* lib/optparse.rb (OptionParser#compsys): escape brackets too.
[ruby-dev:42754]
Mon Dec 27 01:30:08 2010 Tanaka Akira <akr@fsij.org>
* ext/socket/mkconstants.rb: add IF_NAMESIZE.

View file

@ -763,7 +763,7 @@ XXX
to << "#compdef #{name}\n"
to << COMPSYS_HEADER
visit(:compsys, {}, {}) {|o, d|
to << %Q[ "#{o}[#{d.gsub(/\"/, '\"')}]" \\\n]
to << %Q[ "#{o}[#{d.gsub(/[\"\[\]]/, '\\\\\&')}]" \\\n]
}
to << " '*:file:_files' && return 0\n"
end