lib/irby.rb in irby-1.0.1 vs lib/irby.rb in irby-1.1.0
- old
+ new
@@ -1,11 +1,14 @@
require 'irb'
module IRB
def self.start_session(binding)
unless @__irb_initialized
+ args = ARGV.dup
+ ARGV.clear
IRB.setup(nil)
+ ARGV.replace(args)
@__irb_initialized = true
end
workspace = WorkSpace.new(binding)
@@ -18,10 +21,10 @@
irb.eval_input
end
end
end
-module Kernel
+class Object
def irb
IRB.start_session(binding)
end
end