summaryrefslogtreecommitdiff
path: root/test/files/run/t4742.scala
blob: 3b42c0c120931c987d99f467d505970e70a1b667 (plain) (blame)
1
2
3
4
5
6
7
trait T { val x: Int = 0 }
object O extends T { override final val x = 1 }

object Test extends App {
  // was throwing an UnitializedFieldError as constant 1 is folded into the accessor
  assert((O: T).x == 1)
}