Clean up structure of io/console and avoid stty on Windows.#4590
Clean up structure of io/console and avoid stty on Windows.#4590headius merged 1 commit intojruby:jruby-1_7from
Conversation
Fixes jruby#3989. * Restructure the different impls of console into their own files. * Always use stubbed version on Windows. * Cascade from native to stty to stubbed on other platforms.
bd5964f to
43a6732
Compare
|
Request review from @kares, @enebo. This is almost structurally identical to the old one, but the old logic was hard to follow and had unusual guards (like the I believe the new logic is cleaned and more appropriate:
|
|
👍 such a cleanup would be good to have on 9K (pretty much all in one file) |
|
In MRI, io/console is written entirely in C. Part of this reorg is to get files like I will get this into 9k as well since they're both from the same sources. |
This should fix #3989.
I have restructured io/console to be more modular and now force Windows to always use the stubbed version...never the stty version.
Other platforms should work as they did before, but the code is a bit easier to follow now.