Skip to content

Commit b55f95d

Browse files
committed
WIP try to not read empty comments
1 parent c2e97c6 commit b55f95d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

compiler/src/dotty/tools/dotc/core/tasty/CommentUnpickler.scala

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@ class CommentUnpickler(reader: TastyReader) {
2121
val addr = readAddr()
2222
val length = readNat()
2323
val rawComment = readUtf8()
24-
val position = new Span(readLongInt())
25-
comments(addr) = Comment(position, rawComment)
24+
if rawComment.nonEmpty then
25+
val position = new Span(readLongInt())
26+
comments(addr) = Comment(position, rawComment)
2627
}
2728
comments
2829
}

0 commit comments

Comments
 (0)