[swift-evolution] SE-0105: Removing Where Clauses from For-In Loops
wjs at mac.com
Fri Jun 24 17:43:37 CDT 2016
On Jun 24, 2016, at 2:53 PM, Xiaodi Wu <xiaodi.wu at gmail.com> wrote:
> The point I was trying to bring up was that a purported advantage of keeping `where` is moot for those who *do* observe line limits, which includes the Swift stdlib itself as well as (IIUC) house style at Google, Microsoft, etc.
Sorry, I wasn’t clear. I wasn’t saying that having it on the same exactly physical line is cleaner, I was saying that having the criteria for the “what I’m iterating” above the loop body and “what I’m doing with those things” inside the loop body is a much cleaner metaphor to me, and one of my favorite bits of Swift. It feels very Swifty to allow the programmer to separate these two concepts nicely.
I don’t care if/how lines are wrapped. In some cases I put the “where” on the next line in my code right now.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-evolution