Skip to content

for yield with nested pattern does not adapt correctly for lazyZip #19576

Closed
@bishabosha

Description

@bishabosha

Compiler Version

3.4.1-RC1-bin-20240130-7a5cb6e-NIGHTLY

Minimised Code

val a = Seq(0 -> 1, 2 -> 3)
val c = Seq("A", "B")
val z =  for ((beg, end), c) <- a.lazyZip(a) yield c

Output

Wrong number of parameters, expected: 2
for (((beg, end), c) <- a.lazyZip(a)) yield c

Expectation

I am not sure if the error is supposed to happen or not, not understanding all 3.4 deprecations.

It might be related to #18842.

Originally posted by @OndrejSpanel in #19560 (comment)

Metadata

Metadata

Labels

area:desugarDesugaring happens after parsing but before typing, see desugar.scalaarea:typeritype:bugregressionThis worked in a previous version but doesn't anymore

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions