Skip to content

Commit 4954a54

Browse files
committed
Fixes after rebase.
1 parent ef0af37 commit 4954a54

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -973,8 +973,8 @@ class Definitions {
973973
val any = enterCompleteClassSymbol(cls, tpnme.Any, Protected | Final | NoInitsTrait, Nil)
974974
val nothing = enterCompleteClassSymbol(cls, tpnme.Nothing, Protected | Final | NoInitsTrait, List(any.typeRef))
975975

976-
val tparamNames = tpnme.syntheticTypeParamNames(1)
977-
val ptype = PolyType(tparamNames, List(0))(_ => TypeBounds(nothing.typeRef, any.typeRef) :: Nil, PolyParam(_, 0))
976+
val tparamNames = List("P".toTypeName)
977+
val ptype = PolyType(tparamNames)(_ => TypeBounds(nothing.typeRef, any.typeRef) :: Nil, TypeParamRef(_, 0))
978978
newSymbol(cls, nme.assume_, Protected | Final | Method, ptype).entered
979979

980980
cls

compiler/src/dotty/tools/dotc/transform/phantom/PhantomTypeErasure.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class PhantomTypeErasure extends MiniPhaseTransform with InfoTransformer {
4545
case tp: MethodType if tp.resultType.isPhantom =>
4646
// Erase return type to Object to match FunctionN erased return type
4747
val methodType = if (tp.isImplicit) ImplicitMethodType else MethodType
48-
methodType(tp.paramNames, tp.paramTypes, defn.ObjectType)
48+
methodType(tp.paramNames, tp.paramInfos, defn.ObjectType)
4949
case _ => mapOver(tp)
5050
}
5151
}

0 commit comments

Comments
 (0)