diff options
-rw-r--r-- | src/dotty/tools/dotc/core/Denotations.scala | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/dotty/tools/dotc/core/Denotations.scala b/src/dotty/tools/dotc/core/Denotations.scala index aa1442769..fc8bbc84f 100644 --- a/src/dotty/tools/dotc/core/Denotations.scala +++ b/src/dotty/tools/dotc/core/Denotations.scala @@ -637,9 +637,9 @@ object Denotations { */ protected def transformAfter(phase: DenotTransformer, f: SymDenotation => SymDenotation)(implicit ctx: Context): Unit = { var current = symbol.current - while (current.validFor.firstPhaseId < phase.id && (current ne symbol.current)) + while (current.validFor.firstPhaseId < phase.id && (current.nextInRun.validFor.code > current.validFor.code)) current = current.nextInRun - while (current.validFor.firstPhaseId >= phase.id) { + while ((current.validFor.firstPhaseId >= phase.id) && (current.nextInRun.validFor.code > current.validFor.code)) { val current1: SingleDenotation = f(current.asSymDenotation) if (current1 ne current) { current1.validFor = current.validFor @@ -648,7 +648,7 @@ object Denotations { current = current.nextInRun } } - + private def replaceDenotation(current: SingleDenotation): Unit = { var prev = current while (prev.nextInRun ne current) prev = prev.nextInRun |