Function builders

Agreed. I’m taking some time to digest all of this week’s news before I comment on this design.

In the receiver closure thread we were talking about using a $ prefix on the closure. The proposal did address the downsides of this in a DSL like SwiftUI. I haven’t decided how I feel about it overall yet, but omitting usage site syntax for a semantic change like this does feel like a different direction than the rest of Swift has taken. That makes me a little bit uncomfortable, but there are certainly advantages to it as well.

If we ship 5.1 without it and later add support for it how would that impact the evolution of SwiftUI? How much of it’s API is currently living in global scope because it has to, not because it wants to (I’m still getting up to speed on it so I’m not sure of the answer). This seems like an important question.

3 Likes