File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -1566,17 +1566,17 @@ object Types {
1566
1566
/** The denotation currently denoted by this type */
1567
1567
final def denot (implicit ctx : Context ): Denotation = {
1568
1568
val now = ctx.period
1569
- if (checkedPeriod == now) lastDenotation else denotAt(now)
1569
+ val lastd = lastDenotation
1570
+ if (checkedPeriod == now) lastd else denotAt(lastd, now)
1570
1571
}
1571
1572
1572
1573
/** A first fall back to do a somewhat more expensive calculation in case the first
1573
1574
* attempt in `denot` does not yield a denotation.
1574
1575
*/
1575
- private def denotAt (now : Period )(implicit ctx : Context ): Denotation = {
1576
- val d = lastDenotation
1577
- if (d != null && (d.validFor contains now)) {
1576
+ private def denotAt (lastd : Denotation , now : Period )(implicit ctx : Context ): Denotation = {
1577
+ if (lastd != null && (lastd.validFor contains now)) {
1578
1578
checkedPeriod = now
1579
- d
1579
+ lastd
1580
1580
}
1581
1581
else computeDenot
1582
1582
}
You can’t perform that action at this time.
0 commit comments