bug
bug copied to clipboard
Scala 2 bug reports only. Please, no questions — proper bug reports only.
## Reproduction steps In Scala 2.13.8 ```scala type Type[T] = T { type X = Type[T] } ``` Another case: ```scala trait Contra[-F] { def method() :Unit = { type...
## Reproduction steps ```scala Welcome to Scala 2.13.8 (OpenJDK 64-Bit Server VM, Java 17.0.2). Type in expressions for evaluation. Or try :help. scala> class C { implicit override def toString...
## Reproduction steps Scala version: 2.13.8 Override `java.nio.file.Path` as follows... ```scala import java.nio.file.Path import java.nio.file.FileSystem import java.net.URI import java.nio.file.LinkOption import java.nio.file.{WatchKey, WatchService} import java.nio.file.WatchEvent.{Kind, Modifier} class FooPath extends Path {...
## Reproduction steps Scala version: 2.13.8 ``` object Example extends App { def unusedLocal = { val a = 1 2 } } ``` with the compiler option ``` "-Wunused:locals"...
```scala class Test: def foo(x: String)(y: Int): Int = ??? def foo(x: String)(y: Double): Int = ??? ``` This is allowed in Scala 3 , should this be ported to...
```scala trait Cmp[T] { def compareTo(o: T): Int } class K[T] extends Cmp[K[_ >: T]] { def compareTo(that: K[_ >: T]): Int = ??? } object Tst { (new K[String]).compareTo(new...
```scala object crash { def main(args: Array[String]): Unit = { val algo = "HmacSHA1" val charset = java.nio.charset.StandardCharsets.UTF_8 val key = "totally secret key".getBytes(charset) val value = "totally real value".getBytes(charset)...
Most of us know that when you create a value class, there are cases in which the compiler will box/instantiate them. The specific rules are much less known than the...
This snippet fails with a NPE as expected: ``` class A { class B // 1 } val a: A = null val b = new a.B // 2 ```...
The doc data task runs under sbt's 2.12 regime. Either get the task to fork with the build product, or just restore the subproject. Also, restore other manual tweaks to...