Skip to content

Commit dcb3abd

Browse files
committed
Scala3doc: fix issues with loading stdlib
1 parent c1da280 commit dcb3abd

File tree

4 files changed

+6
-7
lines changed

4 files changed

+6
-7
lines changed

compiler/src/scala/quoted/internal/impl/QuoteContextImpl.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1999,16 +1999,16 @@ class QuoteContextImpl private (ctx: Context) extends QuoteContext, QuoteUnpickl
19991999

20002000
object TypeBounds extends TypeBoundsModule:
20012001
def apply(low: TypeRepr, hi: TypeRepr): TypeBounds = Types.TypeBounds(low, hi)
2002-
def unapply(x: TypeBounds): Option[(TypeRepr, TypeRepr)] = Some((x.low, x.hi))
2002+
def unapply(x: TypeBounds): Option[(TypeRepr, TypeRepr)] = Some((x.low.stripLazyRef, x.hi.stripLazyRef))
20032003
def empty: TypeBounds = Types .TypeBounds.empty
20042004
def upper(hi: TypeRepr): TypeBounds = Types .TypeBounds.upper(hi)
20052005
def lower(lo: TypeRepr): TypeBounds = Types .TypeBounds.lower(lo)
20062006
end TypeBounds
20072007

20082008
object TypeBoundsMethodsImpl extends TypeBoundsMethods:
20092009
extension (self: TypeBounds):
2010-
def low: TypeRepr = self.lo
2011-
def hi: TypeRepr = self.hi
2010+
def low: TypeRepr = self.lo.stripLazyRef
2011+
def hi: TypeRepr = self.hi.stripLazyRef
20122012
end extension
20132013
end TypeBoundsMethodsImpl
20142014

project/Build.scala

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1499,8 +1499,7 @@ object Build {
14991499
(`scala3-interfaces`/Compile/products).value,
15001500
(`tasty-core`/Compile/products).value,
15011501
(`scala3-library`/Compile/products).value,
1502-
// TODO we can't load stdlib from Tasty
1503-
// (`stdlib-bootstrapped`/Compile/products).value,
1502+
(`stdlib-bootstrapped`/Compile/products).value,
15041503
).flatten
15051504

15061505
val roots = joinProducts(dottyJars)

scala3doc/src/dotty/dokka/tasty/TypesSupport.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ trait TypesSupport:
104104
case r: Refinement => { //(parent, name, info)
105105
def getRefinementInformation(t: TypeRepr): List[TypeRepr] = t match {
106106
case r: Refinement => getRefinementInformation(r.parent) :+ r
107-
case tr: TypeRef => List(tr)
107+
case t => List(t)
108108
}
109109

110110
def getParamBounds(t: PolyType): List[JProjection] = commas(

scala3doc/src/dotty/dokka/tasty/comments/MemberLookup.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ trait MemberLookup {
5959
import dotty.tools.dotc
6060
given dotc.core.Contexts.Context = rootContext.asInstanceOf
6161
val sym = rsym.asInstanceOf[dotc.core.Symbols.Symbol]
62-
val members = sym.info.decls.iterator
62+
val members = sym.info.decls.iterator.filter(_.denot.isAbsent(false))
6363
// println(s"members of ${sym.show} : ${members.map(_.show).mkString(", ")}")
6464
members.asInstanceOf[Iterator[Symbol]]
6565
}

0 commit comments

Comments
 (0)