Skip to content

REPL :type command produces unexpected error when -Xfatal-warnings compiler option is set #16494

Open
@klaeufer

Description

@klaeufer

Compiler version

3.2.1

Minimized code

build.sbt (tried with sbt 1.7.1 or 1.8.0 and Java 17.0.5-tem)

Compile / scalacOptions ++= Seq("-Xfatal-warnings")
$ sbt consoleQuick
scala> :type 3

Output

-- [E129] Potential Issue Error: -----------------------------------------------
1 |3
  |^
  |A pure expression does nothing in statement position; you may be omitting necessary parentheses
  |
  | longer explanation available when compiling with `-explain`

Expectation

scala> :type 3
Int

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:replarea:reportingError reporting including formatting, implicit suggestions, etcitype:bugstat:changed in nextIssues for which the behaviour is different in Scala Next, but the issue remains valid there.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions