The main REPL related classes and values are as follows.
In addition to standard compiler classes Global and Settings, there are:

History: an interface for session history.
Completion: an interface for tab completion.
ILoop (formerly InterpreterLoop): The umbrella class for a session.
IMain (formerly Interpreter): Handles the evolving state of the session
and handles submitting code to the compiler and handling the output.
InteractiveReader: how ILoop obtains input.
History: an interface for session history.
Completion: an interface for tab completion.
Power: a repository for more advanced/experimental features.

packageinterpreter

The main REPL related classes and values are as follows.
In addition to standard compiler classes Global and Settings, there are:

History: an interface for session history.
Completion: an interface for tab completion.
ILoop (formerly InterpreterLoop): The umbrella class for a session.
IMain (formerly Interpreter): Handles the evolving state of the session
and handles submitting code to the compiler and handling the output.
InteractiveReader: how ILoop obtains input.
History: an interface for session history.
Completion: an interface for tab completion.
Power: a repository for more advanced/experimental features.

The main public entry points are compile(), interpret(), and bind().
The compile() method loads a complete Scala file. The interpret() method
executes one line of Scala code at the request of the user. The bind()
method binds an object to a variable that can then be used by later
interpreted code.

The overall approach is based on compiling the requested code and then
using a Java classloader and Java reflection to run the code
and access its results.

In more detail, a single compiler instance is used
to accumulate all successfully compiled or interpreted Scala code. To
"interpret" a line of code, the compiler generates a fresh object that
includes the line of code and which has public member(s) to export
all variables defined by that code. To extract the result of an
interpreted line to show the user, a second "result object" is created
which imports the variables exported by the above object and then
exports members called "$eval" and "$print". To accommodate user expressions
that read from variables or methods defined in previous statements, "import"
statements are used.

This interpreter shares the strengths and weaknesses of using the
full compiler-to-Java. The main strength is that interpreted code
behaves exactly as does compiled code, including running at full speed.
The main weakness is that redefining classes and methods is not handled
properly, because rebinding at the Java level is technically difficult.