[swift-evolution] [Review] SE-0030 Property Behaviors

Jonathan Tang jonathan.d.tang at gmail.com
Thu Feb 11 13:26:36 CST 2016


On Thu, Feb 11, 2016 at 11:05 AM, Douglas Gregor <dgregor at apple.com> wrote:

>
> On Feb 11, 2016, at 2:12 AM, Jonathan Tang <jonathan.d.tang at gmail.com>
> wrote:
>
>
>
> On Wed, Feb 10, 2016 at 2:00 PM, Douglas Gregor via swift-evolution <
> swift-evolution at swift.org> wrote:
>
>> Hello Swift community,
>>
>> The review of SE-0030 "Property Behaviors" begins now and runs through
>> February, 2016. The proposal is available here:
>>
>>
>> https://github.com/apple/swift-evolution/blob/master/proposals/0030-property-behavior-decls.md
>> <https://github.com/apple/swift-evolution/blob/master/proposals/NNNN-proposal.md>
>>
>> Reviews are an important part of the Swift evolution process. All reviews
>> should be sent to the swift-evolution mailing list at
>>
>> https://lists.swift.org/mailman/listinfo/swift-evolution
>>
>> or, if you would like to keep your feedback private, directly to the
>> review manager. When replying, please try to keep the proposal link at the
>> top of the message:
>>
>> Proposal link:
>>
>>
>> https://github.com/apple/swift-evolution/blob/master/proposals/0030-property-behavior-decls.md
>>
>> Reply text
>>
>> Other replies
>>
>> <https://github.com/apple/swift-evolution#what-goes-into-a-review-1>What
>> goes into a review?
>>
>> The goal of the review process is to improve the proposal under review
>> through constructive criticism and, eventually, determine the direction of
>> Swift. When writing your review, here are some questions you might want to
>> answer in your review:
>>
>>    - What is your evaluation of the proposal?
>>
>> Would it be out-of-scope to propose extending this to functions? [snip]
>
>
> I just want to weigh in on this about expansions of the proposal. I think
> large expansions of the proposal are out-of-scope and should be handled in
> follow-on discussions, particularly in cases where the proposal is already
> fairly large. The big exception here is if the feature as proposed doesn’t
> stand well on its own: for example, it’s not actually useful without some
> particular expansion, so it shouldn’t be accepted. From reading the rest of
> your review, I don’t think you believe that expansion to functions is
> necessary for behaviors to be useful—but that behaviors could be better if
> they were extended to functions. In that case, I’d call it a follow-on
> discussion.
>
> - Doug
>
>
How about contractions of the proposal then? :-)

The only part of the existing proposal that my brainstorm last night
actually changed (as opposed to extended) was the need for behavior-added
methods on properties and a syntax for calling them (the foo.[lazy].clear()
case).  This also seems to be one of the more contentious parts in the
discussion here, and appears to be non-critical in the use-cases listed in
the proposal.  So +1 to the proposal itself, -1 to the ability to add
methods to properties and call them, with the latter perhaps separated out
into a future extension.  +1 for keeping the underbar in the behavior
definition syntax, or even explicitly binding it to a string literal; it
seems quite likely this will be useful.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160211/f0455725/attachment.html>


More information about the swift-evolution mailing list