blob: f0cc07d27ef0f724f28b5b9d7e9872e5ff17dd6b (
plain) (
tree)
|
|
import scala.reflect.runtime.universe._
class Foo(val bar: Int)
object Test extends App {
val foo = new Foo(2)
val tpe = getType(foo)
val bar = tpe.nonPrivateMember(newTermName("bar"))
val value = getValue(foo, bar)
println(value)
}
|