@@ -848,7 +848,7 @@ class Namer { typer: Typer =>
848848 else
849849 try
850850 completeInCreationContext(denot)
851- if (denot.isCompleted) registerIfChild (denot)
851+ if (denot.isCompleted) registerIfChildInCreationContext (denot)
852852 catch
853853 case ex : CompilationUnit .SuspendException =>
854854 val completer = SuspendCompleter ()
@@ -937,10 +937,12 @@ class Namer { typer: Typer =>
937937 denot.markAbsent()
938938 end invalidateIfClashingSynthetic
939939
940- /** If completed symbol is an enum value or a named class, register it as a child
940+ /** Intentionally left without `using Context` parameter.
941+ * This action should be performed in the context of where the completer was created.
942+ * If completed symbol is an enum value or a named class, register it as a child
941943 * in all direct parent classes which are sealed.
942944 */
943- def registerIfChild (denot : SymDenotation )( using Context ): Unit = {
945+ def registerIfChildInCreationContext (denot : SymDenotation ): Unit = {
944946 val sym = denot.symbol
945947
946948 def register (child : Symbol , parentCls : ClassSymbol ) = {
@@ -964,7 +966,7 @@ class Namer { typer: Typer =>
964966 end if
965967 }
966968
967- /** Intentionally left without `implicit ctx ` parameter. We need
969+ /** Intentionally left without `using Context ` parameter. We need
968970 * to pick up the context at the point where the completer was created.
969971 */
970972 def completeInCreationContext (denot : SymDenotation ): Unit = {
0 commit comments