[swift-evolution] [swift-evolution-announce] [Review #2] SE-0161: Smart KeyPaths: Better Key-Value Coding for Swift

Matthew Johnson matthew at anandabits.com
Wed Apr 5 20:56:26 CDT 2017


> 
> What is your evaluation of the proposal?
This proposal is excellent. A big thanks goes out to everyone who worked on it!

The \ sigil may not make for the prettiest syntax but our options are very limited and it is a vast improvement over the previous draft.  If the core team likes the :: suggestion others have made I would be also be fine with that if we could elide the leading `.` in the shorthand version but would prefer not to have to write `::.`.  Overall, the choice of sigil is relatively unimportant to me.  The important thing IMO is that it is concise and will work great in DSLs.

> Is the problem being addressed significant enough to warrant a change to Swift?
Yes.  The lack of unbound property references is a big hole in the language.

> Does this proposal fit well with the feel and direction of Swift?
Absolutely.  

> If you have used other languages or libraries with a similar feature, how do you feel that this proposal compares to those?
I have used lenses a bit in my own code.  Key paths are a really awesome way to build them right into the language with syntactic support that is not possible for libraries.

> How much effort did you put into your review? A glance, a quick reading, or an in-depth study?
In depth study.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20170405/b20d1f28/attachment-0001.html>


More information about the swift-evolution mailing list