summaryrefslogtreecommitdiff
path: root/test/files/neg/t6663.check
diff options
context:
space:
mode:
authorJan Niehusmann <jan@gondor.com>2012-11-13 22:14:34 +0100
committerJan Niehusmann <jan@gondor.com>2012-11-16 23:54:11 +0100
commitc6569209dab006e74ccecc0ede6ce7815ac8629c (patch)
tree32105de312055560c5e2b2fd8b0a089459d460d5 /test/files/neg/t6663.check
parent850108886765e99e894f7613f49c1bab3650a0c2 (diff)
downloadscala-c6569209dab006e74ccecc0ede6ce7815ac8629c.tar.gz
scala-c6569209dab006e74ccecc0ede6ce7815ac8629c.tar.bz2
scala-c6569209dab006e74ccecc0ede6ce7815ac8629c.zip
SI-6663: don't ignore type parameter on selectDynamic invocation
Fix mkInvoke to handle selectDynamic calls of the form new C.foo[T].xyz or new C.foo[T].xyz :U (where C extends Dynamic) Without this patch, the type parameter was silently ignored, and possibly inferred to a different. This patch fixes mkInvoke to handle these cases, where ctxTree has the form Select(TypeApply(fun, targs), nme) or Typed(...)
Diffstat (limited to 'test/files/neg/t6663.check')
-rw-r--r--test/files/neg/t6663.check6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/files/neg/t6663.check b/test/files/neg/t6663.check
new file mode 100644
index 0000000000..aa4faa4a46
--- /dev/null
+++ b/test/files/neg/t6663.check
@@ -0,0 +1,6 @@
+t6663.scala:16: error: type mismatch;
+ found : String
+ required: Int
+ var v = new C(42).foo[String].get :Int
+ ^
+one error found