Skip to content

Commit

Permalink
Accept stale Predef symbol
Browse files Browse the repository at this point in the history
Otherwise we'd get a "stale symbol error" when compiling stdLib in the community build.
  • Loading branch information
odersky committed Nov 21, 2020
1 parent f71b5e7 commit 3b46af1
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions compiler/src/dotty/tools/dotc/core/SymDenotations.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2457,10 +2457,12 @@ object SymDenotations {

/** Possibly accept stale symbol with warning if in IDE */
def acceptStale(denot: SingleDenotation)(using Context): Boolean =
staleOK && {
report.debugwarn(denot.staleSymbolMsg)
true
}
denot.symbol.sourceModule == defn.ScalaPredefModule
|| staleOK
&& {
report.debugwarn(denot.staleSymbolMsg)
true
}

// ---- Completion --------------------------------------------------------

Expand Down

0 comments on commit 3b46af1

Please sign in to comment.