-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Labels
area:reportingError reporting including formatting, implicit suggestions, etcError reporting including formatting, implicit suggestions, etcexp:novicehelp wanted
Description
scala> def foo(a: Int) = a match { case x: Int => x }
1 |def foo(a: Int) = a match { case x: Int => x }
| ^
|this will always yield true, since `class Int` is a subclass of `class Int`
The reason given is a tautology, It would make more sense to say something like "this case will always be taken because the scrutinee `a`
has type Int".
Also, the highlighted position is the position of x
, but it would be more intuitive to highlight the position of x: Int
.
Metadata
Metadata
Assignees
Labels
area:reportingError reporting including formatting, implicit suggestions, etcError reporting including formatting, implicit suggestions, etcexp:novicehelp wanted