> Le 2011-04-21 à 13:45, Jonathan M Davis a écrit : > > TDPL specifically gives it strict semantics. @property functions must be > > called without parens, and non-@property functions must be called with > > them. So, if we want to go with loose semantics, then TDPL will need to > > be changed. > > > > Personally, I don't see much point to @property if its semantics are > > loose. > > Me neither: if the semantics are loose @property serves no purpose. > > But there's still a big problem: the semantics of @property are quite > ambiguous when it comes to the array member syntax. Something needs to be > done about that before @property can be enforced properly. > > I think having a @property-enforced mode, which could stay experimental for > a few releases (activated with a command-line switch), would help test and > sort out many of those issues. I can make a pull request for that -- is > that a good idea?
Sounds good to me, though I know that there are some functions std.file which will become uncallable with strict enforcement due to the fact that property functions cannot currently be overridden with non-property functions, and some functions which should be property functions for strings and non-property functions for ints are currently properties for both, and you can't call a property function on an int. As long as code isn't calling those functions though, they won't pose a problem, and we can find plenty of other issues using the flag. - Jonathan M Davis _______________________________________________ phobos mailing list [email protected] http://lists.puremagic.com/mailman/listinfo/phobos
