Closed
Description
Compiler version
3.3.1-RC1-bin-20230411-d577300-NIGHTLY
Minimized code
ScalaJS allows interoperability with Javascript by creating the facades. The definitions require to provide proper argument list, but the implementation never uses them and is always a call to js.native
@js.native
@JSImport("paper", "Rectangle")
class Rectangle() extends js.Object {
def this(x1: Double, y1: Double, x2: Double, y2: Double) = this()
}
Output
@js.native
@JSImport("paper", "Rectangle")
class Rectangle() extends js.Object {
def this(x1: Double, y1: Double, x2: Double, y2: Double) = this() // unused explicit parameter
}
Expectation
Unused warning is not thrown when js.native
annotation is present in scope of the tree.