Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REPL not aware of actual root imports #11702

som-snytt opened this issue Aug 21, 2019 · 0 comments


Copy link

commented Aug 21, 2019

$ scala -Yimports:java.lang,scala,scala.Predef,scala.util.chaining
Welcome to Scala 2.13.0 (OpenJDK 64-Bit Server VM, Java 11.0.3).
Type in expressions for evaluation. Or try :help.

scala> Set(42).tap(s => println(s.size))
res0: scala.collection.immutable.Set[Int] = Set(42)

scala> :imports
 1) import java.lang._             (136 types, 143 terms)
 2) import scala._                 (179 types, 167 terms)
 3) import scala.Predef._          (100 terms, 58 are implicit)

scala> :quit

It would also be nice if the repl came with three AA batteries:

$ jshell
|  Welcome to JShell -- Version 11.0.3
|  For an introduction type: /help intro

jshell> /imports
|    import*
|    import java.math.*
|    import*
|    import java.nio.file.*
|    import java.util.*
|    import java.util.concurrent.*
|    import java.util.function.*
|    import java.util.prefs.*
|    import java.util.regex.*
|    import*

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
1 participant
You can’t perform that action at this time.