FYI, Wikipedia's article on uniform access is great. http://en.wikipedia.org/wiki/Uniform_access_principle
On Thu, Apr 21, 2011 at 4:30 PM, Robert Jacques <[email protected]> wrote: > On Thu, 21 Apr 2011 15:41:17 -0400, David Simcha <[email protected]> > wrote: > >> On Thu, Apr 21, 2011 at 3:39 PM, Jonathan M Davis >> > > [snip] > > > I know that there are a number of people on the list - particularly newer >>> posters - who fully expect @property to be strict and are surpised when >>> it >>> isn't. And I see _zero_ problem with strong property enforcement as long >>> as >>> the compiler isn't buggy with regards to properties (which it currently >>> is). >>> So, I'm 100% behind strict enforcement. >>> >>> - Jonathan M Davis >>> >> > What about the fact that no two people can agree what should and shouldn't > be a property? Or, more practically, that third party library A won't > conform with organization B's coding policies? Or how about that an O(1) > property which gets re-factored into a big expensive O(N) operation (i.e. > see bug 5813) Or ranges/containers that may all have different mixes of > function-like methods and field-like methods. Speaking of templates, what > about how well/poorly opDispatch, etc compose with @property? Oh, and then > there are entire articles against the @property solution to the field/method > syntax problem in computer science literature (look up the Uniform access > principle used in Ruby and Eiffel). > > Also, surprise isn't necessarily a bad thing. Methods-as-properties > surprised me I received when I first started using D and it put a massive > smile of joy onto my face in the process. > > > _______________________________________________ > phobos mailing list > [email protected] > http://lists.puremagic.com/mailman/listinfo/phobos >
_______________________________________________ phobos mailing list [email protected] http://lists.puremagic.com/mailman/listinfo/phobos
