ufcs and integer params

Chris NS ibisbasenji at gmail.com
Mon Jul 16 01:55:30 PDT 2012


Having been around long enough to remember when the ability to 
call "foo()" as "foo" first appeared, I feel it necessary to 
point out that this was *not* in fact a deliberate design, but 
rather a sort of "accident" that arose out of D's first attempt 
at properties.  It was the same "accident" loaded compiler 
release that gave us pseudo-members -- the precursors to UFCS.

The community discovered that these things were accepted by the 
compiler -- which was actually against the language spec at the 
time -- and further that the resulting code did the intuitively 
correct thing.  Response to the "accidents" being generally 
positive, it was decided to work toward making them legitimate 
language features.  Some flavor of @property (or of a certain 
other proposal which was a mimicry of C# properties... I was in 
that camp) has been in the plan ever since.

I find the ongoing debate/discussion of @property and -property 
to be... well, moot.  But hey, I'm just one crazy among an army 
of crazies.

-- Chris NS


More information about the Digitalmars-d-learn mailing list