Skip to content

Commit a2eb753

Browse files
committed
Fix syntax error and refine which names are cached.
1 parent 3e96c0f commit a2eb753

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

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

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -667,7 +667,8 @@ object Symbols {
667667
case None =>
668668
val idSet = mutable.SortedSet[String]()
669669
tree.foreachSubTree {
670-
case tree: tpd.NameTree if tree.name.isInstanceOf[SimpleName] => idSet += tree.name.toString
670+
case tree: tpd.NameTree if tree.name.toTermName.isInstanceOf[SimpleName] =>
671+
idSet += tree.name.toString
671672
case _ =>
672673
}
673674
val ids = idSet.toArray

language-server/src/dotty/tools/languageserver/DottyLanguageServer.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ class DottyLanguageServer extends LanguageServer
6565

6666
myDrivers = new mutable.HashMap
6767
for (config <- configs) {
68-
implicit class updateDeco(ss: List[String]): List[String] {
68+
implicit class updateDeco(ss: List[String]) {
6969
def update(pathKind: String, pathInfo: String) = {
7070
val idx = ss.indexOf(pathKind)
7171
val ss1 = if (idx >= 0) ss.take(idx) ++ ss.drop(idx + 2) else ss

0 commit comments

Comments
 (0)