File tree Expand file tree Collapse file tree 2 files changed +6
-15
lines changed
scaladoc/src/dotty/tools/scaladoc/tasty Expand file tree Collapse file tree 2 files changed +6
-15
lines changed Original file line number Diff line number Diff line change @@ -485,7 +485,7 @@ trait ClassLikeSupport:
485485
486486
487487 def unwrapMemberInfo (c : ClassDef , symbol : Symbol ): MemberInfo =
488- val baseTypeRepr = memberInfo(c, symbol)
488+ val baseTypeRepr = typeForClass(c).memberType( symbol)
489489
490490 def isSyntheticEvidence (name : String ) =
491491 if ! name.startsWith(NameKinds .EvidenceParamName .separator) then false else
@@ -554,4 +554,4 @@ trait ClassLikeSupport:
554554 if parameters(0 ).symbol.flags.is(Flags .Given ) then " using "
555555 else if parameters(0 ).symbol.flags.is(Flags .Implicit ) then " implicit "
556556 else " "
557- else " "
557+ else " "
Original file line number Diff line number Diff line change @@ -34,25 +34,16 @@ object SyntheticsSupport:
3434 c.constructor.leadingTypeParams.nonEmpty && end <= typesEnd + 1
3535 }
3636
37- /* We need there to filter out symbols with certain flagsets, because these symbols come from compiler and TASTY can't handle them well.
38- They are valdefs that describe case companion objects and cases from enum.
39- TASTY crashed when calling _.tree on them.
40- */
41-
4237 def getSupertypes (using Quotes )(c : reflect.ClassDef ) =
4338 c.symbol.typeRef.baseClasses.map(b => b -> c.symbol.typeRef.baseType(b)).tail
4439
4540 def typeForClass (using Quotes )(c : reflect.ClassDef ): reflect.TypeRepr =
4641 c.symbol.typeRef.appliedTo(c.symbol.typeMembers.filter(_.isTypeParam).map(_.typeRef))
4742
48- def memberInfo (using Quotes )(c : reflect.ClassDef , symbol : reflect.Symbol ): reflect.TypeRepr =
49- import reflect ._
50- import dotty .tools .dotc
51- given dotc .core.Contexts .Context = quotes.asInstanceOf [scala.quoted.runtime.impl.QuotesImpl ].ctx
52- typeForClass(c).asInstanceOf [dotc.core.Types .Type ]
53- .memberInfo(symbol.asInstanceOf [dotc.core.Symbols .Symbol ])
54- .asInstanceOf [TypeRepr ]
55-
43+ /* We need there to filter out symbols with certain flagsets, because these symbols come from compiler and TASTY can't handle them well.
44+ They are valdefs that describe case companion objects and cases from enum.
45+ TASTY crashed when calling _.tree on them.
46+ */
5647 private def hackGetmembers (using Quotes )(rsym : reflect.Symbol ): List [reflect.Symbol ] = {
5748 import reflect ._
5849 import dotty .tools .dotc
You can’t perform that action at this time.
0 commit comments