Skip to content

Commit 7c8156f

Browse files
committed
Fix PostCapture
1 parent 48c8b34 commit 7c8156f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

compiler/src/dotty/tools/dotc/transform/PostCapture.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ import SymDenotations.SymDenotation
1111
import cc.*
1212

1313
/** A denotation transformer that comes after the CheckCaptures. It resets
14-
* all CapturingTypes in the info of derived SingletonDenotations to AnnotatedTypes.
15-
* SymDenotations are left unchaged. For them, the info is already reset in
16-
* Rechecl#updateInfo.
14+
* all CapturingTypes in the info of derived SingletonDenotations to
15+
* regular AnnotatedTypes. SymDenotations are left unchaged. For them,
16+
* the info is already reset in Recheck#updateInfo.
1717
*/
1818
class PostCapture extends Phase, InfoTransformer:
1919
thisPhase =>
@@ -27,7 +27,7 @@ class PostCapture extends Phase, InfoTransformer:
2727
val mapType = new TypeMap:
2828
def apply(t: Type) = t match
2929
case CapturingType(parent, cs) =>
30-
AnnotatedType(this(parent), CaptureAnnotation(cs))
30+
AnnotatedType(this(parent), cs.toRegularAnnotation)
3131
case _ =>
3232
mapOver(t)
3333
mapType(tp)

0 commit comments

Comments
 (0)