Skip to content

Commit 783c252

Browse files
committed
Relax assertion to allow printing trees with overloaded denotations after typer
1 parent ef78fb4 commit 783c252

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/dotc/core/Types.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1826,7 +1826,7 @@ object Types {
18261826

18271827
private def setDenot(denot: Denotation)(implicit ctx: Context): Unit = {
18281828
if (ctx.isAfterTyper)
1829-
assert(!denot.isOverloaded, this)
1829+
assert(!denot.isOverloaded || ctx.mode.is(Mode.Printing), this)
18301830
if (Config.checkNoDoubleBindings)
18311831
if (ctx.settings.YnoDoubleBindings.value)
18321832
checkSymAssign(denot.symbol)

0 commit comments

Comments
 (0)