Skip to content

Commit c19c240

Browse files
committed
Address review comments
1 parent 286a5d6 commit c19c240

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

compiler/src/dotty/tools/dotc/core/SymDenotations.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -863,7 +863,7 @@ object SymDenotations {
863863
/** The module implemented by this module class, NoSymbol if not applicable. */
864864
final def sourceModule(implicit ctx: Context): Symbol = myInfo match {
865865
case ClassInfo(_, _, _, _, selfType) if this is ModuleClass =>
866-
def sourceOfSelf(tp: Any): Symbol = tp match {
866+
def sourceOfSelf(tp: TypeOrSymbol): Symbol = tp match {
867867
case tp: TermRef => tp.symbol
868868
case tp: Symbol => sourceOfSelf(tp.info)
869869
case tp: RefinedType => sourceOfSelf(tp.parent)

compiler/src/dotty/tools/dotc/typer/Implicits.scala

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -525,7 +525,8 @@ trait ImplicitRunInfo { self: Run =>
525525
for (parent <- cls.classParents; ref <- iscopeRefs(tp.baseType(parent.classSymbol)))
526526
addRef(ref)
527527
}
528-
if (tp.widen.typeSymbol.isOpaqueAlias) addCompanionOf(tp.widen.typeSymbol)
528+
val underlyingTypeSym = tp.widen.typeSymbol
529+
if (underlyingTypeSym.isOpaqueAlias) addCompanionOf(underlyingTypeSym)
529530
else tp.classSymbols(liftingCtx).foreach(addClassScope)
530531
case _ =>
531532
for (part <- tp.namedPartsWith(_.isType)) comps ++= iscopeRefs(part)

0 commit comments

Comments
 (0)