<html><body><div style="color:#000; background-color:#fff; font-family:arial, helvetica, sans-serif;font-size:12pt"><div><span>I've proposed in the past that functions which have no arguments and return void could be callable without parentheses, as they cannot be mistaken for properties.<br></span></div><div><br><span></span></div><div><span>I think we all agree that non-@property functions which take a single parameter should not be callable in property form.</span></div><div><br><span></span></div><div><span>Functions that are not properties which return a value should be required to have parentheses to distinguish them from properties.<br></span></div><div><br><span></span></div><div><span>The above is all consistent with TDPL as far as I know.<br></span></div><div><br><span></span></div><div><span>-Steve<br></span></div><div><br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><div style="font-family:
arial,helvetica,sans-serif; font-size: 12pt;"><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;"><font face="Arial" size="2"><hr size="1"><b><span style="font-weight: bold;">From:</span></b> David Simcha <dsimcha@gmail.com><br><b><span style="font-weight: bold;">To:</span></b> Discuss the phobos library for D <phobos@puremagic.com><br><b><span style="font-weight: bold;">Sent:</span></b> Thursday, April 21, 2011 10:09 AM<br><b><span style="font-weight: bold;">Subject:</span></b> Re: [phobos] Time to get ready for the next release<br></font><br><meta http-equiv="x-dns-prefetch-control" content="off"><div id="yiv235344225">As I've said before, we really need to decide whether @property has loose or strict semantics. Loose semantics means that non-@property functions would still be callable without (), etc but @property functions wouldn't be allowed to have ()s. Frankly, I hate @property, want to to have
as little effect as possible, like the flexibility of being able to call the same function both ways, and would have a lot of code break if this were taken away, so my vote is loose semantics.<br>
<br><div class="yiv235344225gmail_quote">On Thu, Apr 21, 2011 at 9:24 AM, Michel Fortin <span dir="ltr"><<a rel="nofollow" ymailto="mailto:michel.fortin@michelf.com" target="_blank" href="mailto:michel.fortin@michelf.com">michel.fortin@michelf.com</a>></span> wrote:<br><blockquote class="yiv235344225gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Le 2011-04-21 à 6:48, Torarin a écrit :<br>
<div class="yiv235344225im"><br>
> Dmd has a bug that causes the @property attribute to be disregarded in<br>
> functions that return auto.<br>
<br>
</div>Indeed. I think I have a fix for that in the "@property" branch of my DMD fork on github. Perhaps I should make a pull request from that.<br>
<br>
Actually, I could make a pull request for the entire "@property" branch, it shouldn't impact things much as enforcement of @property is only done if you add the command line switch -property. Would that make sense?<br>
<div class="yiv235344225im"><br>
--<br>
Michel Fortin<br>
<a rel="nofollow" ymailto="mailto:michel.fortin@michelf.com" target="_blank" href="mailto:michel.fortin@michelf.com">michel.fortin@michelf.com</a><br>
<a rel="nofollow" target="_blank" href="http://michelf.com/">http://michelf.com/</a><br>
<br>
<br>
<br>
_______________________________________________<br>
</div><div><div></div><div class="yiv235344225h5">phobos mailing list<br>
<a rel="nofollow" ymailto="mailto:phobos@puremagic.com" target="_blank" href="mailto:phobos@puremagic.com">phobos@puremagic.com</a><br>
<a rel="nofollow" target="_blank" href="http://lists.puremagic.com/mailman/listinfo/phobos">http://lists.puremagic.com/mailman/listinfo/phobos</a><br>
</div></div></blockquote></div><br>
</div><meta http-equiv="x-dns-prefetch-control" content="on"><br>_______________________________________________<br>phobos mailing list<br><a ymailto="mailto:phobos@puremagic.com" href="mailto:phobos@puremagic.com">phobos@puremagic.com</a><br><a href="http://lists.puremagic.com/mailman/listinfo/phobos" target="_blank">http://lists.puremagic.com/mailman/listinfo/phobos</a><br><br></div></div></blockquote></div></div></body></html>