diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-03-22 04:31:24 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-03-22 04:31:24 +0000 |
commit | e689d077e30d4680af140be5549a369590e3db39 (patch) | |
tree | fe6bc16aecb02d55f2c8501d4840418566a2e8ea /lib/optparse.rb | |
parent | 9b3344c94d527d58886c5774f77d3cec01e472d1 (diff) |
* lib/optparse.rb, lib/jcode.rb, ext/tk/lib/tk.rb: reorder character
class /[\]\[]/ to /[\[\]]/ to readability.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3598 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/optparse.rb')
-rw-r--r-- | lib/optparse.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/optparse.rb b/lib/optparse.rb index 1da5ef2cc0..ea1ba61356 100644 --- a/lib/optparse.rb +++ b/lib/optparse.rb @@ -965,7 +965,7 @@ Default options, which never appear in option summary. raise ArgumentError, "unsupported argument type: #{o}" when *ArgumentStyle.keys style = notwice(ArgumentStyle[o], style, 'style') - when /^--no-([^\]\[=\s]*)(.+)?/ + when /^--no-([^\[\]=\s]*)(.+)?/ q, a = $1, $2 o = notwice(a ? Object : TrueClass, klass, 'type') not_pattern, not_conv = search(:atype, o) unless not_style @@ -975,7 +975,7 @@ Default options, which never appear in option summary. ldesc << "--no-#{q}" long << 'no-' + (q = q.downcase) nolong << q - when /^--\[no-\]([^\]\[=\s]*)(.+)?/ + when /^--\[no-\]([^\[\]=\s]*)(.+)?/ q, a = $1, $2 o = notwice(a ? Object : TrueClass, klass, 'type') if a @@ -987,7 +987,7 @@ Default options, which never appear in option summary. not_pattern, not_conv = search(:atype, FalseClass) unless not_style not_style = Switch::NoArgument nolong << 'no-' + o - when /^--([^\]\[=\s]*)(.+)?/ + when /^--([^\[\]=\s]*)(.+)?/ q, a = $1, $2 if a o = notwice(NilClass, klass, 'type') |