diff --git a/ChangeLog b/ChangeLog index dc675a9357..4af54c8293 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Wed Jul 22 02:33:57 2009 Keiju Ishitsuka + + * lib/irb.rb: forget svn commit. + Wed Jul 22 01:20:54 2009 Yukihiro Matsumoto * bootstraptest/test_io.rb: block write may block for long time. diff --git a/lib/irb.rb b/lib/irb.rb index 17d4ae51bd..d914f06a7a 100644 --- a/lib/irb.rb +++ b/lib/irb.rb @@ -65,12 +65,20 @@ module IRB irb.signal_handle end - catch(:IRB_EXIT) do - irb.eval_input + begin + catch(:IRB_EXIT) do + irb.eval_input + end + ensure + irb_at_exit end # print "\n" end + def IRB.irb_at_exit + @CONF[:AT_EXIT].each{|hook| hook.call} + end + def IRB.irb_exit(irb, ret) throw :IRB_EXIT, ret end