summaryrefslogtreecommitdiff
path: root/test/files/pos/t5744
diff options
context:
space:
mode:
authorEugene Burmako <xeno.by@gmail.com>2014-01-11 23:41:31 +0100
committerEugene Burmako <xeno.by@gmail.com>2014-01-12 12:06:03 +0100
commit5cc8f83c681ded7367dc5112f6f9042e9526facf (patch)
tree3d656851b1f59e1e8b52df95d18aacfa5d6dc45c /test/files/pos/t5744
parente089cafb5fd02e2457bafde3252da3a771d3180e (diff)
downloadscala-5cc8f83c681ded7367dc5112f6f9042e9526facf.tar.gz
scala-5cc8f83c681ded7367dc5112f6f9042e9526facf.tar.bz2
scala-5cc8f83c681ded7367dc5112f6f9042e9526facf.zip
*boxContext => *box.Context , *boxMacro => *box.Macro
Performs the following renamings: * scala.reflect.macros.BlackboxContext to scala.reflect.macros.blackbox.Context * scala.reflect.macros.BlackboxMacro to scala.reflect.macros.blackbox.Macro * scala.reflect.macros.WhiteboxContext to scala.reflect.macros.whitebox.Context * scala.reflect.macros.WhiteboxMacro to scala.reflect.macros.whitebox.Macro https://groups.google.com/forum/#!topic/scala-internals/MX40-dM28rk
Diffstat (limited to 'test/files/pos/t5744')
-rw-r--r--test/files/pos/t5744/Macros_1.scala6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/files/pos/t5744/Macros_1.scala b/test/files/pos/t5744/Macros_1.scala
index 0fc13c12d7..6e2bf4825b 100644
--- a/test/files/pos/t5744/Macros_1.scala
+++ b/test/files/pos/t5744/Macros_1.scala
@@ -1,18 +1,18 @@
import scala.language.experimental.macros
-import scala.reflect.macros.BlackboxContext
+import scala.reflect.macros.blackbox.Context
object Macros {
def foo[U: Numeric](x: U) = macro foo_impl[U]
def bar[U: Numeric : Equiv, Y <% String](x: U)(implicit s: String) = macro bar_impl[U, Y]
- def foo_impl[U](c: BlackboxContext)(x: c.Expr[U])(numeric: c.Expr[Numeric[U]]) = {
+ def foo_impl[U](c: Context)(x: c.Expr[U])(numeric: c.Expr[Numeric[U]]) = {
import c.universe._
val plusOne = Apply(Select(numeric.tree, newTermName("plus")), List(x.tree, Literal(Constant(1))))
val body = Apply(Select(Ident(definitions.PredefModule), newTermName("println")), List(plusOne))
c.Expr[Unit](body)
}
- def bar_impl[U, Y](c: BlackboxContext)(x: c.Expr[U])(numeric: c.Expr[Numeric[U]], equiv: c.Expr[Equiv[U]], viewAsString: c.Expr[Y => String], s: c.Expr[String]) = {
+ def bar_impl[U, Y](c: Context)(x: c.Expr[U])(numeric: c.Expr[Numeric[U]], equiv: c.Expr[Equiv[U]], viewAsString: c.Expr[Y => String], s: c.Expr[String]) = {
import c.universe._
val plusOne = Apply(Select(numeric.tree, newTermName("plus")), List(x.tree, Literal(Constant(1))))
val plusLen = Apply(Select(numeric.tree, newTermName("plus")), List(plusOne, Select(s.tree, newTermName("length"))))