blob: b4660e258ef0a058be0affb80d6231156fe72a8b (
plain) (
tree)
|
|
import scala.tools.partest.ReplTest
object Test extends ReplTest {
def code = """
import scala.reflect.macros.BlackboxContext
import language.experimental.macros
def impl1(c: BlackboxContext) = { import c.universe._; c.Expr[Unit](q"()") }
def foo1: Unit = macro impl1
foo1
def impl2(c: BlackboxContext)() = { import c.universe._; c.Expr[Unit](q"()") }
def foo2(): Unit = macro impl2
foo2()
def impl3(c: BlackboxContext)(x: c.Expr[Int])(y: c.Expr[Int]) = { import c.universe._; c.Expr[Unit](q"()") }
def foo3(x: Int)(y: Int): Unit = macro impl3
foo3(2)(3)
"""
}
|