Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-08 Thread Naoto Sato
On Tue, 6 Dec 2022 18:10:38 GMT, Naoto Sato wrote: >> src/java.base/share/classes/java/io/Console.java line 99: >> >>> 97: */ >>> 98: >>> 99: public class Console implements Flushable >> >> Should we perhaps `seal` this class and only `permit` `ProxyingConsole` to >> `extend` it? > > Right.

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-06 Thread Naoto Sato
On Tue, 6 Dec 2022 07:34:45 GMT, Alan Bateman wrote: >> src/java.base/share/classes/java/io/Console.java line 616: >> >>> 614: >>> JdkConsoleProvider.DEFAULT_PROVIDER_MODULE_NAME); >>> 615: return >>> ServiceLoader.load(JdkConsoleProvider.class).stream()

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-06 Thread Naoto Sato
On Tue, 6 Dec 2022 06:19:37 GMT, Jaikiran Pai wrote: >> Naoto Sato has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed the copyright year > > src/java.base/share/classes/java/io/Console.java line 99: > >> 97: */ >> 98: >> 99: public

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-06 Thread Alan Bateman
On Tue, 6 Dec 2022 07:35:44 GMT, Jaikiran Pai wrote: > So the `Console` instance returned from `System.console()`, thus far, follows > these semantics. However, with the change proposed in this PR, the default > implementation will now be the jline backed `JdkConsoleImpl` implementation. > Fro

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Alan Bateman
On Tue, 6 Dec 2022 07:08:55 GMT, Jaikiran Pai wrote: > Furthermore, I think in its current form it means that this will > load/instantiate any `JdkConsoleProvider` implementations that are accessible > to the thread context classloader but may not have been from the module > configured through

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jaikiran Pai
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jaikiran Pai
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jaikiran Pai
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jaikiran Pai
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jaikiran Pai
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jaikiran Pai
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jaikiran Pai
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Jim Laskey
On Mon, 5 Dec 2022 19:52:59 GMT, Naoto Sato wrote: >> This is to allow Console to be used even when it is not attached to the >> platform provided terminal, such as the case when the standard input is >> redirected. `System.console()` now returns a Console implementation based on >> `jdk.inter

Re: RFR: 8295803: Console should be usable in jshell and other environments [v7]

2022-12-05 Thread Naoto Sato
> This is to allow Console to be used even when it is not attached to the > platform provided terminal, such as the case when the standard input is > redirected. `System.console()` now returns a Console implementation based on > `jdk.internal.le` terminal by default, or jshell implementation if