[swift-evolution] [Proposal] Property behaviors

David Waite david at alkaline-solutions.com
Thu Dec 24 00:30:48 CST 2015

There was a proposal as well to get property accessor method access directly, without referencing the function. 

If you had obj#myProperty.get() -> Val and obj#myProperty.set(_:Val) as functions (# syntax being a placeholder more than a proposal) perhaps then you could also have something like obj#myProperty.clear()


> On Dec 23, 2015, at 10:07 AM, Joe Groff via swift-evolution <swift-evolution at swift.org> wrote:
> I agree that "myProperty.clear()" is very appealing, but it has the potential to be confusing when behavior methods are shadowed by members of the front-facing property. You'd still need a way to unambiguously refer to behavior methods when they're shadowed too.
> -Joe

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20151223/7baf5696/attachment.html>

More information about the swift-evolution mailing list