Closed
Description
Hey there. I tested the newly released scala.js support in dotty and came across this problem in facade code. It doesn't need scala.js enabled to reproduce.
Minimized code
// minimized scala.js
package object js {
def native: Nothing = ???
}
// minimized facade
object Object {
def assign[T, U](target: T, source: U): T with U = js.native
}
Output
Get the following error message
[error] | class Nothing in package scala does not take type parameters
Expectation
Should compile.
The code compiles if the package object is changed to a normal object, or if the return type in assign
is changed to a concrete type