diff options
author | Paul Phillips <paulp@improving.org> | 2012-02-02 13:13:55 -0800 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2012-02-02 14:29:50 -0800 |
commit | f411950e43fbf56306f96bbc8803ba278d25f440 (patch) | |
tree | dbd964365851f6c675d33536805c8fa1c32e755b /src/compiler | |
parent | f55db64983edfeb9484b7617e2b59f8994c37ef3 (diff) | |
download | scala-f411950e43fbf56306f96bbc8803ba278d25f440.tar.gz scala-f411950e43fbf56306f96bbc8803ba278d25f440.tar.bz2 scala-f411950e43fbf56306f96bbc8803ba278d25f440.zip |
matchesType fixup.
Diffstat (limited to 'src/compiler')
-rw-r--r-- | src/compiler/scala/reflect/internal/Types.scala | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/compiler/scala/reflect/internal/Types.scala b/src/compiler/scala/reflect/internal/Types.scala index c8b960ebe8..2c01008efe 100644 --- a/src/compiler/scala/reflect/internal/Types.scala +++ b/src/compiler/scala/reflect/internal/Types.scala @@ -5459,8 +5459,8 @@ trait Types extends api.Types { self: SymbolTable => matchesType(tp1, res2, true) case MethodType(_, _) => false - case PolyType(tparams2, res2) => - tparams2.isEmpty && matchesType(tp1, res2, alwaysMatchSimple) + case PolyType(_, _) => + false case _ => alwaysMatchSimple || tp1 =:= tp2 } @@ -5478,7 +5478,7 @@ trait Types extends api.Types { self: SymbolTable => case ExistentialType(_, res2) => alwaysMatchSimple && matchesType(tp1, res2, true) case TypeRef(_, sym, Nil) => - params1.isEmpty && sym.isModuleClass && matchesType(res1, sym.tpe, alwaysMatchSimple) + params1.isEmpty && sym.isModuleClass && matchesType(res1, tp2, alwaysMatchSimple) case _ => false } @@ -5491,7 +5491,7 @@ trait Types extends api.Types { self: SymbolTable => case ExistentialType(_, res2) => alwaysMatchSimple && matchesType(tp1, res2, true) case TypeRef(_, sym, Nil) if sym.isModuleClass => - matchesType(res1, sym.tpe, alwaysMatchSimple) + matchesType(res1, tp2, alwaysMatchSimple) case _ => matchesType(res1, tp2, alwaysMatchSimple) } @@ -5514,8 +5514,8 @@ trait Types extends api.Types { self: SymbolTable => } case TypeRef(_, sym, Nil) if sym.isModuleClass => tp2 match { - case MethodType(Nil, res2) => matchesType(sym.tpe, res2, alwaysMatchSimple) - case NullaryMethodType(res2) => matchesType(sym.tpe, res2, alwaysMatchSimple) + case MethodType(Nil, res2) => matchesType(tp1, res2, alwaysMatchSimple) + case NullaryMethodType(res2) => matchesType(tp1, res2, alwaysMatchSimple) case _ => lastTry } case _ => |