On Saturday, 19 January 2013 at 02:50:35 UTC, Andrey wrote:
This all falls apart once you decide you need "friend" access.

I haven't seen such situations yet. According to OOP concept they must be very rare, so I tend to consider them more of architecture and logic mistake (and C++ is one big architecture and logic frankenstein).

Sorry for being a little harsh, but there's a big warning sign on the Overview page of this site:

Who D is Not For:
Language purists. D is a practical language, and each feature of it is evaluated in that light, rather than by an ideal.

All of this stuff about pure (or true) OOP concept, when you just don't need such hacks as "friend" is good on paper. But most of the time it's very expensive to stick with such kind of purity rigorously.

Or even is just a completely bad idea. Consider algorithms for data structures being members in true-OO vs. STL/D-ranges approach or everything is a function with no side-effects in "pure" functional languages.

Reply via email to