Closed
Description
Compiler version
3.3.1
Minimized code
https://scastie.scala-lang.org/1OfTRArhRuKz5Kq59dUcHg
final abstract class ForcedRecompilationToken[T]
object ForcedRecompilationToken {
implicit def default: ForcedRecompilationToken["abc"] = null
}
class GoodNoParens[T](implicit ev: ForcedRecompilationToken[T])
type BadNoParens[T] = GoodNoParens[T]
// error
object A extends BadNoParens
// ok
object B extends BadNoParens()
object C extends GoodNoParens
object App extends App {
println("compiled")
}
Output
GoodNoParens is not a class type
Expectation
Similar situation as in #15976, but this time merely using a type alias to refer to the class breaks the fix for the aforementioned issue and causes a spurious 'not a class type' error.