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 @@ -258,11 +258,11 @@ class DottyLanguageServer extends LanguageServer
258258 def lookup (name : Name ): Symbol = {
259259 imp.expr.tpe.member(name).symbol
260260 }
261- val importedSyms = imp.selectors.flatMap {
262- case id : Ident if id.pos.contains(pos.pos ) =>
263- lookup(id.name) :: lookup(id.name.toTypeName) :: Nil
264- case thicket @ Thicket ((id : Ident ) :: (_ : Ident ) :: Nil ) if thicket.pos.contains(pos.pos ) =>
265- lookup(id.name) :: lookup(id.name.toTypeName) :: Nil
261+ val importedSyms = imp.selectors.find(_.pos.contains(pos.pos)) match {
262+ case Some ( id : Ident ) =>
263+ lookup(id.name.toTermName ) :: lookup(id.name.toTypeName) :: Nil
264+ case Some ( Thicket ((id : Ident ) :: (_ : Ident ) :: Nil )) =>
265+ lookup(id.name.toTermName ) :: lookup(id.name.toTypeName) :: Nil
266266 case _ =>
267267 Nil
268268 }
You can’t perform that action at this time.
0 commit comments