blob: 603500b597c2ec2b13d26ac46f7573693939652e (
plain) (
tree)
|
|
import scala.reflect.macros.blackbox.Context
object Impls {
def foo(c: Context): c.Expr[Int] = {
import c.universe._
c.Expr(Literal(Constant("42")))
}
}
object Macros {
def foo: Int = macro Impls.foo
}
|