I like what this idea attempts to do, but have you thought of simply allowing 
extensions of types within the same module to access private members and 
declare stored properties? Adding a whole new construct to the language—while 
technically not source-breaking—would in practice change what is considered to 
be the idiomatic “Swifty” way of extending your own types, forcing people who 
care about such things to revisit their code for (imo) no good reason.

As a separate point, I’m strongly against the requirement that continuations be 
named and declared within the original type declaration or other continuations. 
As an optional categorization feature I’d be ok with it, but naming is hard, 
and forcing me to come up with a name every time I wish to isolate 
functionality of my types will push me away from doing it in the first place. 
Not to mention when I inevitably change one of my horrible continuation names, 
I will have to change it in two places (or more in the cross-platform example)!

Also on the naming point, you mention being able to refer to continuations by 
name. Can you give an example where that would be useful?
_______________________________________________
swift-evolution mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to