Skip to content

Commit 070d1bb

Browse files
kasiaMarekWojciechMazur
authored andcommitted
bugfix: add moduleClass imported symbols in IndexedContext
[Cherry-picked 2531498]
1 parent ddc505a commit 070d1bb

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

presentation-compiler/src/main/dotty/tools/pc/IndexedContext.scala

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import scala.util.control.NonFatal
55

66
import dotty.tools.dotc.core.Contexts.*
77
import dotty.tools.dotc.core.Flags.*
8+
import dotty.tools.dotc.core.NameOps.moduleClassName
89
import dotty.tools.dotc.core.Names.*
910
import dotty.tools.dotc.core.Symbols.*
1011
import dotty.tools.dotc.core.Types.*
@@ -170,7 +171,11 @@ object IndexedContext:
170171
initial ++ fromPackageObjects
171172

172173
def fromImport(site: Type, name: Name)(using Context): List[Symbol] =
173-
List(site.member(name.toTypeName), site.member(name.toTermName))
174+
List(
175+
site.member(name.toTypeName),
176+
site.member(name.toTermName),
177+
site.member(name.moduleClassName),
178+
)
174179
.flatMap(_.alternatives)
175180
.map(_.symbol)
176181

0 commit comments

Comments
 (0)