Closed
Description
The following code typechecks OK, but gives a type error when inlining. I believe that should not happen, since the error is in library code.
object Test {
val unit = ()
def f[T <: Tuple, X](xs: T, x: X) =
xs ++ x *: unit
}
The error I get is:
5 |sealed trait Tuple extends Any {
| ^^^^^^^^^^^^^^^
| found: Tuple.Concat[T(xs)(Tuple_this), (T$27 *: T$28)(that)]
| required: Tuple.Concat[T(xs), (X *: Unit(Test.unit))(?1)]
|
| where: ?1 is an unknown value of type X *: Unit(Test.unit)
| This location is in code that was inlined at matchtypes.scala:6
Also, it seems the position is wrong for the error.
Metadata
Metadata
Assignees
Labels
No labels