Skip to content

Error message doesn't disambiguate names enough #4184

Closed
@Blaisorblade

Description

@Blaisorblade

In #4180, note that the error message is very misleading; even after this comparison is allowed, I'd expect this issue to apply to other examples:

object Bar {
  true == (true: java.lang.Boolean)
}

gives

-- Error: /tmp/scastie843852333271942738/src/main/scala/main.scala:3:2 ---------
3 |  true == (true: java.lang.Boolean)
  |  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  |  Values of types Boolean and Boolean cannot be compared with == or !=

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:reportingError reporting including formatting, implicit suggestions, etcitype:enhancement

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions