Extending D's support for object-oriented design with private(this)
NotYouAgain
NotYouAgain at gmail.com
Tue Apr 30 05:49:10 UTC 2024
On Tuesday, 30 April 2024 at 02:00:19 UTC, Lance Bachmeier wrote:
> ... If you make the case that this does not lead to a demand
> for friends, which I see as a strong argument, then maybe it'll
> have a chance. I think it's a reasonable addition to the
> language,...
But I'm arguing against friends, not for friends.
Friends already exist - ie, all code in the module is C++ friend
to your class, like it or not.
For people that don't like the idea that C++ like friendship
might come to D, well. it's already here.. on steriods.
Again, my single, only motivation, is to be able to declare a
private member in my class in the module.
Why that is soooo.... contentious, is utterly bewildering.
The D designer completely changed the “right” and “obvious”
meaning for private.
Did he really expect there would be no pushback on that?
More information about the dip.ideas
mailing list