File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
language-server/src/dotty/tools/languageserver Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -262,11 +262,11 @@ class DottyLanguageServer extends LanguageServer
262
262
def lookup (name : Name ): Symbol = {
263
263
imp.expr.tpe.member(name).symbol
264
264
}
265
- val importedSyms = imp.selectors.flatMap {
266
- case id : Ident if id.pos.contains(pos.pos ) =>
267
- lookup(id.name) :: lookup(id.name.toTypeName) :: Nil
268
- case thicket @ Thicket ((id : Ident ) :: (_ : Ident ) :: Nil ) if thicket.pos.contains(pos.pos ) =>
269
- lookup(id.name) :: lookup(id.name.toTypeName) :: Nil
265
+ val importedSyms = imp.selectors.find(_.pos.contains(pos.pos)) match {
266
+ case Some ( id : Ident ) =>
267
+ lookup(id.name.toTermName ) :: lookup(id.name.toTypeName) :: Nil
268
+ case Some ( Thicket ((id : Ident ) :: (_ : Ident ) :: Nil )) =>
269
+ lookup(id.name.toTermName ) :: lookup(id.name.toTypeName) :: Nil
270
270
case _ =>
271
271
Nil
272
272
}
You can’t perform that action at this time.
0 commit comments