mirror of
https://github.com/ruby/ruby.git
synced 2025-08-24 21:44:30 +02:00
![]() (https://github.com/ruby/irb/pull/835)
* Remove unnecessary code from the exit command's implementation
1. The parameters of `IRB.irb_exit` were never used. But there are some
libraries seem to call it with arguments + it's declared on the top-level
IRB constant. So I changed the params to anonymous splat instead of removing them.
2. `Context#exit` was completely unnecessary as `IRB.irb_exit` doesn't use
the `@irb` instance it passes. And since it's (or should be treated as)
a private method, I simply removed it.
3. The `exit` command doesn't use the status argument it receives at all.
But to avoid raising errors on usages like `exit 1`, I changed the argument to
anonymous splat instead removing it.
* Make exit an actual command
* Update readme
|
||
---|---|---|
.. | ||
backtrace.rb | ||
break.rb | ||
catch.rb | ||
chws.rb | ||
continue.rb | ||
debug.rb | ||
delete.rb | ||
edit.rb | ||
exit.rb | ||
finish.rb | ||
help.rb | ||
history.rb | ||
info.rb | ||
irb_info.rb | ||
load.rb | ||
ls.rb | ||
measure.rb | ||
next.rb | ||
nop.rb | ||
pushws.rb | ||
show_cmds.rb | ||
show_doc.rb | ||
show_source.rb | ||
step.rb | ||
subirb.rb | ||
whereami.rb |