File tree 2 files changed +7
-3
lines changed
compiler/src/dotty/tools/dotc
2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -1305,8 +1305,10 @@ object Trees {
1305
1305
this (this (x, arg), annot)
1306
1306
case Thicket (ts) =>
1307
1307
this (x, ts)
1308
- case _ if ctx.reporter.errorsReported =>
1309
- // in case of errors it may be that typed trees point to untyped ones.
1308
+ case _ if ctx.mode.is(Mode .Interactive ) =>
1309
+ // In case of errors it may be that typed trees point to untyped ones.
1310
+ // The IDE can still traverse inside such trees, either in the run where errors
1311
+ // are reported, or in subsequent ones.
1310
1312
x
1311
1313
}
1312
1314
}
Original file line number Diff line number Diff line change @@ -1538,7 +1538,9 @@ object Types {
1538
1538
else recomputeMember(d) // symbol could have been overridden, recompute membership
1539
1539
else {
1540
1540
val newd = loadDenot
1541
- if (newd.exists) newd else d.staleSymbolError
1541
+ if (newd.exists) newd
1542
+ else if (ctx.mode.is(Mode .Interactive )) d
1543
+ else d.staleSymbolError
1542
1544
}
1543
1545
case d =>
1544
1546
if (d.validFor.runId != ctx.period.runId) loadDenot
You can’t perform that action at this time.
0 commit comments