Closed nicorichard closed 2 years ago
A minimally reproducible example for 0.49.8
0.49.8
func foo(index: Int) { for index in 0..<1 {} print(index) }
will be formatted to
func foo(index _: Int) { for index in 0..<1 {} print(index) // compile error }
This seems to be a regression which may have been caused by the solution for my previous issue #1174
The issue does not occur for version 0.49.6
0.49.6
Another example of a failing case in the same category:
func foo(index: Int) { for (index, value) in [].enumerated() {} print(index) }
Seems like a duplicate of https://github.com/nicklockwood/SwiftFormat/issues/1183 - I've landed a fix in develop already.
@nicorichard fixed in 0.49.9
A minimally reproducible example for
0.49.8
will be formatted to
This seems to be a regression which may have been caused by the solution for my previous issue #1174
The issue does not occur for version
0.49.6
Another example of a failing case in the same category: