Skip to content

Commit 3a74f7c

Browse files
committed
Removed extraneous debug println.
1 parent 0f78b20 commit 3a74f7c

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

src/dotty/tools/dotc/transform/Erasure.scala

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -251,17 +251,9 @@ object Erasure extends TypeTestsCasts{
251251
override def typedLiteral(tree: untpd.Literal)(implicit ctc: Context): Literal =
252252
if (tree.typeOpt.isRef(defn.UnitClass)) tree.withType(tree.typeOpt)
253253
else super.typedLiteral(tree)
254-
255-
// The following methods, typedIf, typedMatch and typedTry need to compensate
256-
// for the fact that after erasure, a subtype may notbe compatible with the
257-
// type of a lub. Hence we might need to readapt branches to the common type.
258-
// Note that the typing of SeqLiteral faces a similar problem but solves it
259-
// differently: It adapts all elements to the erasure of the type that existed
260-
// before. TODO: It looks like a good idea to harmonize this.
261-
//
254+
262255
override def typedIf(tree: untpd.If, pt: Type)(implicit ctx: Context): If = {
263256
val tree1 = super.typedIf(tree, pt)
264-
println(i"typed if $tree1 with $pt = ${tree1.tpe}")
265257
if (pt.isValueType) tree1
266258
else cpy.If(tree1)(thenp = adapt(tree1.thenp, tree1.tpe), elsep = adapt(tree1.elsep, tree1.tpe))
267259
}

0 commit comments

Comments
 (0)