aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-12-05 03:09:34 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-12-05 03:09:34 +0000
commit504e6b4dacf4071ffc8ead7460098fe560de4f04 (patch)
treea44d11167b995f5cc2b2c001cd783598a14faa9e
parentaf54c1694cc4139d06797475f9091664d83d8a75 (diff)
downloadruby-504e6b4dacf4071ffc8ead7460098fe560de4f04.tar.gz
* lib/irb/init.rb (IRB.parse_opts): fix typo. [ruby-core:33574]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog4
-rw-r--r--lib/irb/init.rb2
-rw-r--r--test/irb/test_option.rb12
3 files changed, 17 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index ea63eb8798..d12cc150b6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Sun Dec 5 12:09:27 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * lib/irb/init.rb (IRB.parse_opts): fix typo. [ruby-core:33574]
+
Sun Dec 5 11:27:08 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* ruby.c (load_file_internal): decrement for ungotten line.
diff --git a/lib/irb/init.rb b/lib/irb/init.rb
index 5c1d56e980..2d7ff3146e 100644
--- a/lib/irb/init.rb
+++ b/lib/irb/init.rb
@@ -207,7 +207,7 @@ module IRB
IRB.print_usage
exit 0
when "--"
- if opt = ARGV.shfit
+ if opt = ARGV.shift
@CONF[:SCRIPT] = opt
$0 = opt
end
diff --git a/test/irb/test_option.rb b/test/irb/test_option.rb
new file mode 100644
index 0000000000..846d7185a5
--- /dev/null
+++ b/test/irb/test_option.rb
@@ -0,0 +1,12 @@
+require 'test/unit'
+require_relative '../ruby/envutil'
+
+module TestIRB
+ class TestOption < Test::Unit::TestCase
+ def test_end_of_option
+ bug4117 = '[ruby-core:33574]'
+ status = assert_in_out_err(%w[-rirb -e IRB.start(__FILE__) -- --], "", //, [], bug4117)
+ assert(status.success?, bug4117)
+ end
+ end
+end