This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these messages)
|
JShell is a Java read-eval-print loop which was first introduced in the JDK 9.[1] It is tracked by JEP 222 jshell: The Java Shell (Read-Eval-Print Loop).[2] One reason why JShell was proposed for Java 9 is the lack of a standard interactive environment for the language; the de facto library to use a Java REPL was often BeanShell, which has been dormant since 2003, and arbitrarily diverged from the Java language.[3][4]
Provide an interactive tool to evaluate declarations, statements, and expressions of the Java programming language, together with an API so that other applications can leverage this functionality
Another alternative is to maintain the status quo: Use another language or use a third-party REPL such as BeanShell, though that particular REPL has been dormant for many years, is based on JDK 1.3, and makes arbitrary changes to the language.
BeanShell (just like Groovy, too by the way) made an attempt of standardisation by the Java Community Process in JSR 274 – a JSR that did not produce any notable output, in spite of the fact that (or perhaps because?) two major companies, Sun and Google, had joined the expert group. Under the JCP.next initiative this JSR was declared "Dormant".