@@ -675,7 +675,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
675675 javaSelectOnType(qual2)
676676
677677 case _ =>
678- errorTree(tree, " cannot convert to type selection" ) // will never be printed due to fallback
678+ errorTree(tree, em " cannot convert to type selection " ) // will never be printed due to fallback
679679 }
680680
681681 def selectWithFallback (fallBack : Context ?=> Tree ) =
@@ -1534,8 +1534,8 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
15341534 case _ =>
15351535 if (mt.isParamDependent)
15361536 errorTree(tree,
1537- i """ cannot turn method type $mt into closure
1538- |because it has internal parameter dependencies """ )
1537+ em """ cannot turn method type $mt into closure
1538+ |because it has internal parameter dependencies """ )
15391539 else if ((tree.tpt `eq` untpd.ContextualEmptyTree ) && mt.paramNames.isEmpty)
15401540 // Note implicitness of function in target type since there are no method parameters that indicate it.
15411541 TypeTree (defn.FunctionOf (Nil , mt.resType, isContextual = true , isErased = false ))
@@ -1783,7 +1783,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
17831783 var body1 = typedType(cdef.body, pt)
17841784 if ! body1.isType then
17851785 assert(ctx.reporter.errorsReported)
1786- body1 = TypeTree (errorType(" <error: not a type>" , cdef.srcPos))
1786+ body1 = TypeTree (errorType(em " <error: not a type> " , cdef.srcPos))
17871787 assignType(cpy.CaseDef (cdef)(pat2, EmptyTree , body1), pat2, body1)
17881788 }
17891789 caseRest(using ctx.fresh.setFreshGADTBounds.setNewScope)
@@ -1931,7 +1931,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
19311931 .withType(
19321932 if isFullyDefined(pt, ForceDegree .flipBottom) then pt
19331933 else if ctx.reporter.errorsReported then UnspecifiedErrorType
1934- else errorType(i " cannot infer type; expected type $pt is not fully defined " , tree.srcPos))
1934+ else errorType(em " cannot infer type; expected type $pt is not fully defined " , tree.srcPos))
19351935
19361936 def typedTypeTree (tree : untpd.TypeTree , pt : Type )(using Context ): Tree =
19371937 tree match
@@ -1945,7 +1945,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
19451945 // untyped tree is no longer accessed after all
19461946 // accesses with typedTypeTree are done.
19471947 case None =>
1948- errorTree(tree, " Something's wrong: missing original symbol for type tree" )
1948+ errorTree(tree, em " Something's wrong: missing original symbol for type tree " )
19491949 }
19501950 case _ =>
19511951 completeTypeTree(InferredTypeTree (), pt, tree)
@@ -1986,9 +1986,9 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
19861986 tree.args match
19871987 case arg :: _ if arg.isTerm =>
19881988 if Feature .dependentEnabled then
1989- return errorTree(tree, i " Not yet implemented: T(...) " )
1989+ return errorTree(tree, em " Not yet implemented: T(...) " )
19901990 else
1991- return errorTree(tree, dependentStr )
1991+ return errorTree(tree, dependentMsg )
19921992 case _ =>
19931993
19941994 val tpt1 = withoutMode(Mode .Pattern ) {
@@ -2127,9 +2127,9 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
21272127
21282128 def typedTermLambdaTypeTree (tree : untpd.TermLambdaTypeTree )(using Context ): Tree =
21292129 if Feature .dependentEnabled then
2130- errorTree(tree, i " Not yet implemented: (...) =>> ... " )
2130+ errorTree(tree, em " Not yet implemented: (...) =>> ... " )
21312131 else
2132- errorTree(tree, dependentStr )
2132+ errorTree(tree, dependentMsg )
21332133
21342134 def typedMatchTypeTree (tree : untpd.MatchTypeTree , pt : Type )(using Context ): Tree = {
21352135 val bound1 =
@@ -2161,7 +2161,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
21612161
21622162 def typedBind (tree : untpd.Bind , pt : Type )(using Context ): Tree = {
21632163 if ! isFullyDefined(pt, ForceDegree .all) then
2164- return errorTree(tree, i " expected type of $tree is not fully defined " )
2164+ return errorTree(tree, em " expected type of $tree is not fully defined " )
21652165 val body1 = typed(tree.body, pt)
21662166 body1 match {
21672167 case UnApply (fn, Nil , arg :: Nil )
@@ -3779,7 +3779,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
37793779 else
37803780 val meth = methPart(tree).symbol
37813781 if meth.isAllOf(DeferredInline ) && ! Inlines .inInlineMethod then
3782- errorTree(tree, i " Deferred inline ${meth.showLocated} cannot be invoked " )
3782+ errorTree(tree, em " Deferred inline ${meth.showLocated} cannot be invoked " )
37833783 else if Inlines .needsInlining(tree) then
37843784 tree.tpe <:< wildApprox(pt)
37853785 val errorCount = ctx.reporter.errorCount
0 commit comments