Skip to content

Commit cb9fcd8

Browse files
committed
Add comment
1 parent 4f775fa commit cb9fcd8

File tree

1 file changed

+1
-0
lines changed
  • compiler/src/dotty/tools/dotc/transform/patmat

1 file changed

+1
-0
lines changed

compiler/src/dotty/tools/dotc/transform/patmat/Space.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -941,6 +941,7 @@ object SpaceEngine {
941941
val msg = if nullOnly then MatchCaseOnlyNullWarning() else MatchCaseUnreachable()
942942
report.warning(msg, pat.srcPos)
943943

944+
// in redundancy check, take guard as false in order to soundly approximate
944945
val newPrev = if guard.isEmpty then covered :: prevs else prevs
945946
recur(rest, newPrev, Nil)
946947

0 commit comments

Comments
 (0)