scala 3 repl does not show if a message is an error or a warning (regression from scala 2)
See original GitHub issueCompiler version
3.0.0
Minimized code and output
scala> val x = if true then 42
1 |val x = if true then 42
| ^^
|A pure expression does nothing in statement position; you may be omitting necessary parentheses
scala> val x = val
1 |val x = val
| ^^^
| expression expected but val found
Expectation
The first message above should include warning
and the the second should include error
. It is conceptually important to understand if the code has run or not, esp. for learners but also for professionals - I don’t know all messages by hart if they are warnings or errors. Now it all looks the same in the Scala 3 REPL.
This is a regression from the Scala 2 REPL, in which you can always tell if a message is an error or a warning.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:2
- Comments:27 (26 by maintainers)
Top Results From Across the Web
Scala 3 REPL commands · Issue #131 - GitHub
Background Per our discussion, the Scala 2.13 REPL has these commands: scala> :help All commands ... I can't determine if dotr has any...
Read more >Configuring and suppressing warnings in Scala
In projects where the build log shows a lot of warnings that are mostly ignored, new helpful warnings can easily go undetected.
Read more >Ammonite REPL
The goal of Ammonite is to liberate your Scala code from heavyweight "projects", using the lightweight Ammonite runtime: if you want to run...
Read more >Release Notes · Airframe - wvlet.github.io
Upgrade to Scala 2.13.10 to address a regression in Scala 2.13.9. ... This version shows warning messages if you are still using public...
Read more >Blog · mdoc - javadoc.io
Fast typechecked markdown documentation with clear error messages ... Unlike tut, mdoc does not use the Scala REPL to evaluate Scala code examples....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
All tests pass in CI build. 🥳
@bishabosha Found it: compiler/test/dotty/tools/repl/ShadowingTests.scala