From 8686ee186197b3aeea3cfbe53014e36fb5ce9eac Mon Sep 17 00:00:00 2001 From: usa Date: Sat, 10 Jun 2006 01:20:24 +0000 Subject: * lib/getoptlong.rb (GetoptLong#set_options): recieve arguments as Array. * lib/irb/slex.rb: use Proc#yield. * lib/rdoc/markup/simple_markup/inline.rb: follow the new behavior of String#[]. * lib/rdoc/ri/ri_write.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10239 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/getoptlong.rb | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'lib/getoptlong.rb') diff --git a/lib/getoptlong.rb b/lib/getoptlong.rb index 922d25371c..880883a981 100644 --- a/lib/getoptlong.rb +++ b/lib/getoptlong.rb @@ -289,14 +289,7 @@ class GetoptLong @canonical_names.clear @argument_flags.clear - arguments.each do |arg| - # - # Each argument must be an Array. - # - if !arg.is_a?(Array) - raise ArgumentError, "the option list contains non-Array argument" - end - + arguments.each do |*arg| # # Find an argument flag and it set to `argument_flag'. # -- cgit v1.2.3