Skip to content

Commit b0469ac

Browse files
committed
Make local dummies legal parts of methods.
< and > are invalid in method names, so we now use ( and ) instead. local dummies can end up as parts of method names that are made not private.
1 parent 70ad514 commit b0469ac

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/dotty/tools/dotc/core/StdNames.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ object StdNames {
104104
val INTERPRETER_LINE_PREFIX: N = "line"
105105
val INTERPRETER_VAR_PREFIX: N = "res"
106106
val INTERPRETER_WRAPPER_SUFFIX: N = "$object"
107-
val LOCALDUMMY_PREFIX: N = "<local " // owner of local blocks
107+
val LOCALDUMMY_PREFIX: N = "(local " // owner of local blocks
108108
val MODULE_SUFFIX: N = NameTransformer.MODULE_SUFFIX_STRING
109109
val AVOID_CLASH_SUFFIX: N = "$_avoid_name_clash_$"
110110
val MODULE_VAR_SUFFIX: N = "$module"
@@ -714,7 +714,7 @@ object StdNames {
714714
(0 until num).map(syntheticParamName)(breakOut)
715715

716716
def localDummyName(clazz: Symbol)(implicit ctx: Context): TermName =
717-
LOCALDUMMY_PREFIX ++ clazz.name ++ ">"
717+
LOCALDUMMY_PREFIX ++ clazz.name ++ ")"
718718

719719
def newBitmapName(bitmapPrefix: TermName, n: Int): TermName = bitmapPrefix ++ n.toString
720720

0 commit comments

Comments
 (0)