@@ -621,30 +621,6 @@ object Denotations {
621621 throw ex
622622 case _ => Signature .NotAMethod
623623
624- private var myCurrentJavaSig : Signature = uninitialized
625- private var myCurrentJavaSigRunId : RunId = NoRunId
626- private var myCurrentScala2Sig : Signature = uninitialized
627- private var myCurrentScala2SigRunId : RunId = NoRunId
628- private var myCurrentSig : Signature = uninitialized
629- private var myCurrentSigRunId : RunId = NoRunId
630-
631- def currentSignature (sourceLanguage : SourceLanguage )(using Context ): Signature = sourceLanguage match
632- case SourceLanguage .Java =>
633- if myCurrentJavaSigRunId != ctx.runId then
634- myCurrentJavaSig = signature(sourceLanguage)
635- myCurrentJavaSigRunId = ctx.runId
636- myCurrentJavaSig
637- case SourceLanguage .Scala2 =>
638- if myCurrentScala2SigRunId != ctx.runId then
639- myCurrentScala2Sig = signature(sourceLanguage)
640- myCurrentScala2SigRunId = ctx.runId
641- myCurrentScala2Sig
642- case SourceLanguage .Scala3 =>
643- if myCurrentSigRunId != ctx.runId then
644- myCurrentSig = signature(sourceLanguage)
645- myCurrentSigRunId = ctx.runId
646- myCurrentSig
647-
648624 def derivedSingleDenotation (symbol : Symbol , info : Type , pre : Type = this .prefix, isRefinedMethod : Boolean = this .isRefinedMethod)(using Context ): SingleDenotation =
649625 if ((symbol eq this .symbol) && (info eq this .info) && (pre eq this .prefix) && (isRefinedMethod == this .isRefinedMethod)) this
650626 else newLikeThis(symbol, info, pre, isRefinedMethod)
@@ -1047,8 +1023,8 @@ object Denotations {
10471023 val thisLanguage = SourceLanguage (symbol)
10481024 val otherLanguage = SourceLanguage (other.symbol)
10491025 val commonLanguage = SourceLanguage .commonLanguage(thisLanguage, otherLanguage)
1050- val sig = currentSignature (commonLanguage)
1051- val otherSig = other.currentSignature (commonLanguage)
1026+ val sig = signature (commonLanguage)
1027+ val otherSig = other.signature (commonLanguage)
10521028 sig.matchDegree(otherSig) match
10531029 case FullMatch =>
10541030 ! alwaysCompareTypes || info.matches(other.info)
0 commit comments