[ruby/irb] Changed to call Kernel.print
If you call `binding.irb` on a class defined `#print`, it will crash, so call `Kernel.print`. Fix [Bug #18389] `binding.irb` can fail in some classes that implement `context` and `print` methods. https://github.com/ruby/irb/commit/d54b271984
This commit is contained in:
parent
e714163011
commit
b6b2e489f1
@ -235,7 +235,7 @@ module IRB # :nodoc:
|
||||
alias_method to, from
|
||||
}
|
||||
else
|
||||
print "irb: warn: can't alias #{to} from #{from}.\n"
|
||||
Kernel.print "irb: warn: can't alias #{to} from #{from}.\n"
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user