<html><body><div>Ah, you are right, of course! I was thinking of annotations with a name for XML- or JSON-Mapping. Wrong track of thought... :-)<br></div><div><br></div><div>-Thorsten<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div><br>Am 19. Februar 2016 um 08:05 schrieb Curt Clifton <curt@curtclifton.net>:<br><br><div><blockquote type="cite"><div class="msg-quote"><div class="_stretch"><span class="body-text-content">On Feb 18, 2016, at 10:09 PM, Thorsten Seitz <tseitz42@icloud.com> wrote:<br><br><blockquote type="cite" class="quoted-plain-text"><blockquote type="cite" class="quoted-plain-text">Besides eliminating the odd naked “declaration”, this has the added advantage that it could be extended to `bind initialValue, propertyName`. :-)</blockquote></blockquote><blockquote type="cite" class="quoted-plain-text"><br></blockquote><blockquote type="cite" class="quoted-plain-text">Couldn't we just add a name by introducing an accessor to be implemented by the user of a property?</blockquote><br>What would that look like? Would the programmer have to give the name of the property twice? Like so:<br><br>```<br>@plistBacked var warningTextColor: NSColor {<br> name {<br> return warningTextColor<br> }<br>}<br>```<br><br>While that works as a stop gap, the repetition is an invitation to error. It would be much better to just write:<br><br>```<br>@plistBacked var warningTextColor: NSColor<br>```<br><br>and make the property's name available to the behavior's implementation, much as the property's declaring type is exposed as `self`.<br><br>But this is also largely off-topic for the thread. I was arguing for a better way to declare that initialValue should be bound and suggesting that a `bind` construct might be an approach that is extensible in the future.<br><br>Cheers,<br><br>Curt</span></div></div></blockquote></div></div></body></html>