blob: 25a6575dc36a8006511673c8fd01041a701980e9 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
import scala.reflect.mirror._
object Test extends App {
class MyQuerycollection{
def findUserByName( name:String ) = {
val tree = reify{ "test" == name }
val toolbox = mkToolBox()
toolbox.typeCheck(tree) match{
case Apply(Select(lhs,op),rhs::Nil) =>
println(rhs.tpe)
}
}
}
val qc = new MyQuerycollection
qc.findUserByName("some value")
}
|