aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/TypeErasure.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-10-24 18:13:13 +0200
committerMartin Odersky <odersky@gmail.com>2014-10-26 16:24:01 +0100
commita426e9280aa7ed3dbad923a8b2110b6a1a281771 (patch)
treea6449f1b154821ca267acc0301ec4c9bc4242bfa /src/dotty/tools/dotc/TypeErasure.scala
parent651ff01e07b90c481e30afdd1500f617d74aeeb4 (diff)
downloaddotty-a426e9280aa7ed3dbad923a8b2110b6a1a281771.tar.gz
dotty-a426e9280aa7ed3dbad923a8b2110b6a1a281771.tar.bz2
dotty-a426e9280aa7ed3dbad923a8b2110b6a1a281771.zip
Fixes erasure of super
- supertype components needs to be recursively erased Without this fix, some files do not pass -Ycheck:lambdaLift
Diffstat (limited to 'src/dotty/tools/dotc/TypeErasure.scala')
-rw-r--r--src/dotty/tools/dotc/TypeErasure.scala4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/TypeErasure.scala b/src/dotty/tools/dotc/TypeErasure.scala
index 50aaafc82..851be7658 100644
--- a/src/dotty/tools/dotc/TypeErasure.scala
+++ b/src/dotty/tools/dotc/TypeErasure.scala
@@ -258,8 +258,10 @@ class TypeErasure(isJava: Boolean, isSemi: Boolean, isConstructor: Boolean, wild
else this(parent)
case tp: TermRef =>
this(tp.widen)
- case ThisType(_) | SuperType(_, _) =>
+ case ThisType(_) =>
tp
+ case SuperType(thistpe, supertpe) =>
+ SuperType(this(thistpe), this(supertpe))
case ExprType(rt) =>
MethodType(Nil, Nil, this(rt))
case tp: TypeProxy =>