When compared for equality, nested case classes with type parameters do not check for their parent object. Tried on latest Dotty nightly. Scala 2 shows expected behavior ## minimized code ```Scala trait T { case class X[A]() } object a extends T object b extends T val ax = a.X() val bx = b.X() println(ax == bx) ``` ## expectation The equality check should print `false` but prints `true`. Deleting the type parameter `[A]` on the case class shows the correct behavior.