Skip to content

Commit

Permalink
Merge pull request #14963 from dotty-staging/fix-14953
Browse files Browse the repository at this point in the history
Adapt infos of export default getters to qualifier
  • Loading branch information
bishabosha authored Apr 20, 2022
2 parents 78b6070 + fb5f380 commit 9ed0762
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
3 changes: 2 additions & 1 deletion compiler/src/dotty/tools/dotc/typer/Namer.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1185,7 +1185,8 @@ class Namer { typer: Typer =>
buf += ddef.withSpan(span)
if hasDefaults then
foreachDefaultGetterOf(sym.asTerm,
getter => addForwarder(getter.name.asTermName, getter, span))
getter => addForwarder(
getter.name.asTermName, getter.asSeenFrom(path.tpe), span))
end addForwarder

def addForwardersNamed(name: TermName, alias: TermName, span: Span): Unit =
Expand Down
8 changes: 8 additions & 0 deletions tests/pos/i14953.scala
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
object Test{

val xs: Seq[String] = List("Apple", "Orange", "Pear")
export xs.*

}

val _ = Test.head

0 comments on commit 9ed0762

Please sign in to comment.