Blog post: What D got wrong
Mike Franklin
slavo5150 at yahoo.com
Wed Dec 12 04:28:57 UTC 2018
On Tuesday, 11 December 2018 at 14:38:25 UTC, Steven
Schveighoffer wrote:
> @property: This was almost about to be awesome, but squabbling
> amongst the D core team killed it.
Yes, the problem with @property is that it is neither correctly
implemented nor completely implemented. And to do the former
something will have to break.
Note that you can't use binary assignment operators on
parentheses-less function calls, and returning by ref is not a
solution either. Not only does that break encapsulation, but some
@property functions may not return an addressable lvalue (e.g.
when working with bitfields).
One might be able to fix the @property implementation, but now,
there's so much disdain for the incorrect, incomplete @property
implementation it's going to take some serious sweetener to
remove the bitter taste from some people's mouths.
Mike
More information about the Digitalmars-d-announce
mailing list