summaryrefslogtreecommitdiff
path: root/test/files/run/reflect-resolveoverload-targs.scala
diff options
context:
space:
mode:
authorJosh Suereth <Joshua.Suereth@gmail.com>2012-07-30 11:39:19 -0700
committerJosh Suereth <Joshua.Suereth@gmail.com>2012-07-30 11:39:19 -0700
commit00fd27c3b4355054c883a15e08b6cc2449ae9253 (patch)
tree457b080d9e25590954ee809aad5acff5929ce602 /test/files/run/reflect-resolveoverload-targs.scala
parent147e6c2768c13312144b92f1c34a53cc178212a2 (diff)
parent7d8c46479104a694c79a18861a1713a0a65e89f1 (diff)
downloadscala-00fd27c3b4355054c883a15e08b6cc2449ae9253.tar.gz
scala-00fd27c3b4355054c883a15e08b6cc2449ae9253.tar.bz2
scala-00fd27c3b4355054c883a15e08b6cc2449ae9253.zip
Merge pull request #960 from clhodapp/remove-resolve-overloaded
Remove resolveOverloaded
Diffstat (limited to 'test/files/run/reflect-resolveoverload-targs.scala')
-rw-r--r--test/files/run/reflect-resolveoverload-targs.scala29
1 files changed, 0 insertions, 29 deletions
diff --git a/test/files/run/reflect-resolveoverload-targs.scala b/test/files/run/reflect-resolveoverload-targs.scala
deleted file mode 100644
index 888b2f0c15..0000000000
--- a/test/files/run/reflect-resolveoverload-targs.scala
+++ /dev/null
@@ -1,29 +0,0 @@
-
-import reflect.runtime.{universe=>u}
-import scala.reflect.runtime.{currentMirror => cm}
-
-class C {
- def foo[T: u.TypeTag](x: String) = 1
- def foo[T: u.TypeTag, S: u.TypeTag](x: String) = 2
-}
-
-object Test extends App {
- val c = new C
- val im = cm.reflect(c)
- val foo = u.typeOf[C] member u.newTermName("foo") asTermSymbol
- val f1 = foo.resolveOverloaded(
- targs = Seq(u.typeOf[Int]),
- posVargs = Seq(u.typeOf[String])
- )
-
- val f2 = foo.resolveOverloaded(
- targs = Seq(u.typeOf[Int],
- u.typeOf[Int]), posVargs = Seq(u.typeOf[String])
- )
-
- val m1 = im.reflectMethod(f1 asMethodSymbol)
- val m2 = im.reflectMethod(f2 asMethodSymbol)
-
- assert(m1("a", u.typeTag[Int]) == c.foo[Int]("a"))
- assert(m2("a", u.typeTag[Int], u.typeTag[Int]) == c.foo[Int, Int]("a"))
-}