summaryrefslogtreecommitdiff
path: root/src/compiler
diff options
context:
space:
mode:
authorJosh Suereth <Joshua.Suereth@gmail.com>2012-11-20 17:41:41 -0800
committerJosh Suereth <Joshua.Suereth@gmail.com>2012-11-20 17:41:41 -0800
commit29293ab56e61cc8bdb97210a04554ed4829b0ff3 (patch)
tree8f56797a5425e5222361e9ad8c483d643fff6c0a /src/compiler
parent087aebe3ee1b93aafc654ea623cb0e289a8170a8 (diff)
parentc6569209dab006e74ccecc0ede6ce7815ac8629c (diff)
downloadscala-29293ab56e61cc8bdb97210a04554ed4829b0ff3.tar.gz
scala-29293ab56e61cc8bdb97210a04554ed4829b0ff3.tar.bz2
scala-29293ab56e61cc8bdb97210a04554ed4829b0ff3.zip
Merge pull request #1621 from jannic/SI-6663-2.10.x
Si 6663 2.10.x fix type parameter on selectDynamic
Diffstat (limited to 'src/compiler')
-rw-r--r--src/compiler/scala/tools/nsc/typechecker/Typers.scala7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala
index d3847de894..80785cee2f 100644
--- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala
+++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala
@@ -3935,9 +3935,14 @@ trait Typers extends Modes with Adaptations with Tags {
case t: ValOrDefDef => t.rhs
case t => t
}
- val (outer, explicitTargs) = cxTree1 match {
+ val cxTree2 = cxTree1 match {
+ case Typed(t, tpe) => t // ignore outer type annotation
+ case t => t
+ }
+ val (outer, explicitTargs) = cxTree2 match {
case TypeApply(fun, targs) => (fun, targs)
case Apply(TypeApply(fun, targs), args) => (Apply(fun, args), targs)
+ case Select(TypeApply(fun, targs), nme) => (Select(fun, nme), targs)
case t => (t, Nil)
}
def hasNamedArg(as: List[Tree]) = as.collectFirst{case AssignOrNamedArg(lhs, rhs) =>}.nonEmpty