1 2 3 4 5 6 7 8 9 10
trait X { val elem: Int = 1 } module test { def g(x: X) = x.elem; def f(x: Object) = x.toString(); }