Skip to content

Commit 9c26189

Browse files
committed
1 parent 3c1e15e commit 9c26189

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

compiler/src/dotty/tools/dotc/ast/Desugar.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1582,7 +1582,7 @@ object desugar {
15821582
if gen.checkMode == GenCheckMode.FilterAlways then // pattern was prefixed by `case`
15831583
false
15841584
else
1585-
gen.checkMode != GenCheckMode.FilterNow
1585+
gen.checkMode == GenCheckMode.Ignore
15861586
|| isVarBinding(gen.pat)
15871587
|| isIrrefutable(gen.pat, gen.expr)
15881588

compiler/test-resources/repl/i14626

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// scalac: -source:future
2+
scala> for (a, b) <- List("a","b","c").lazyZip(List(1,2,3)) do println(s"$a$b")
3+
a1
4+
b2
5+
c3

0 commit comments

Comments
 (0)