aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/typer
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2016-09-05 14:30:17 +0200
committerMartin Odersky <odersky@gmail.com>2016-10-02 16:11:21 +0200
commit33545570039fa37be3327f0ba8c27d16b0d7abf6 (patch)
tree672745adc8c6f58038d6c3e0729f3e1aeb2158a6 /src/dotty/tools/dotc/typer
parent4dd8469391c440728fa8ee4e45d521b7933d5bd8 (diff)
downloaddotty-33545570039fa37be3327f0ba8c27d16b0d7abf6.tar.gz
dotty-33545570039fa37be3327f0ba8c27d16b0d7abf6.tar.bz2
dotty-33545570039fa37be3327f0ba8c27d16b0d7abf6.zip
Fix bugs related to type parameter remapping
- Remap typerefs - Register types in TypeTrees
Diffstat (limited to 'src/dotty/tools/dotc/typer')
-rw-r--r--src/dotty/tools/dotc/typer/Inliner.scala3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/typer/Inliner.scala b/src/dotty/tools/dotc/typer/Inliner.scala
index a0df735b1..631c98734 100644
--- a/src/dotty/tools/dotc/typer/Inliner.scala
+++ b/src/dotty/tools/dotc/typer/Inliner.scala
@@ -155,7 +155,7 @@ class Inliner(call: tpd.Tree, rhs: tpd.Tree)(implicit ctx: Context) {
}
private def registerLeaf(tree: Tree): Unit = tree match {
- case _: This | _: Ident => registerType(tree.tpe)
+ case _: This | _: Ident | _: TypeTree => registerType(tree.tpe)
case _ =>
}
@@ -213,6 +213,7 @@ class Inliner(call: tpd.Tree, rhs: tpd.Tree)(implicit ctx: Context) {
val typeMap = new TypeMap {
def apply(t: Type) = t match {
case t: ThisType => thisProxy.getOrElse(t, t)
+ case t: TypeRef => paramProxy.getOrElse(t, t)
case t: SingletonType => paramProxy.getOrElse(t, t)
case t => mapOver(t)
}