blob: 63240e9801f0dfea34c6d850ed499be87c875269 (
plain) (
tree)
|
|
// https://github.com/lampepfl/dotty/issues/1065
package hello
object world {
def mkArray(atype: Int): Array[_ <: AnyVal] = {
(if (atype == 1) new Array[Int](10) else new Array[Float](10))
}
def main(args: Array[String]): Unit = {
println(mkArray(1))
}
}
|