Skip to content

Commit 6e38791

Browse files
committed
Make SymbolMethods.isSuperAccessor experimental
1 parent d8ebb13 commit 6e38791

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

library/src/scala/quoted/Quotes.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3619,6 +3619,7 @@ trait Quotes { self: runtime.QuoteUnpickler & runtime.QuoteMatching =>
36193619
def isClassConstructor: Boolean
36203620

36213621
/** Is this the super accessor? */
3622+
@experimental // TODO when stable, remove `dotty.tools.scaladoc.tasty.ClassLikeSupport.isSuperBridgeMethod` and use this method
36223623
def isSuperAccessor: Boolean
36233624

36243625
/** Is this the definition of a type? */

scaladoc/src/dotty/tools/scaladoc/tasty/ClassLikeSupport.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ trait ClassLikeSupport:
249249
extension (c: ClassDef)
250250
def extractMembers: Seq[Member] = {
251251
val inherited = c.getNonTrivialInheritedMemberTrees.collect {
252-
case dd: DefDef if !dd.symbol.isClassConstructor && !(dd.symbol.isSuperAccessor || dd.symbol.isDefaultHelperMethod) => dd
252+
case dd: DefDef if !dd.symbol.isClassConstructor && !(dd.symbol.isSuperBridgeMethod || dd.symbol.isDefaultHelperMethod) => dd
253253
case other => other
254254
}
255255
c.membersToDocument.flatMap(parseMember(c)) ++

scaladoc/src/dotty/tools/scaladoc/tasty/SyntheticSupport.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ object SyntheticsSupport:
2121
import reflect._
2222
s.flags.is(Flags.Synthetic) || s.flags.is(Flags.FieldAccessor) || s.isDefaultHelperMethod
2323

24+
// TODO remove and use `SymbolMethods.isSuperAccessor`
2425
def isSuperBridgeMethod: Boolean = s.name.contains("$super$")
2526

2627
def isDefaultHelperMethod: Boolean = ".*\\$default\\$\\d+$".r.matches(s.name)

0 commit comments

Comments
 (0)