Possible @property compromise

Michel Fortin michel.fortin at michelf.ca
Thu Jan 31 07:40:18 PST 2013


On 2013-01-31 14:50:40 +0000, "Steven Schveighoffer" 
<schveiguy at yahoo.com> said:

> It actually is a bit depressing, we have to reset the clock back to 
> late  2009 to start over with properties...

I haven't participated in the discussions about properties this time 
around because it's pretty obvious to me it's getting nowhere.

It seems to me that nothing can be done at this point in time if we 
want to avoid a breakage of almost all current D code. Well, we could 
make some compromises, but a compromise is going to complicate things 
while solving only some of the issues; few of us will be really 
satisfied with such a thing.

By the way I was a big proponent of properties with no semantic 
ambiguities back in 2009. I even proposed a getX/setX scheme, which I 
still like very much. I'd like to see real properties in D, but I don't 
think it's realistic at this point.

And you have to admit that the way D does properties today is both 
simple, clever, and appealing. It does have some error-prone 
liabilities when it comes to callable types and generic programming 
especially, but beside that I do like the design of the thing. It's a 
natural extension of UFCS, even though it predates UFCS. Perhaps we 
should just call it a day and live with the ambiguities. I don't like 
it, but I don't see any viable alternative.


-- 
Michel Fortin
michel.fortin at michelf.ca
http://michelf.ca/



More information about the Digitalmars-d mailing list