Why do some language-defined attributes have @ and some not?

Shriramana Sharma via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Fri Oct 24 06:53:06 PDT 2014


Hi people and thanks for weighing in. It's nice to note that there's
already a DIP on this. I hope it's refined and implemented in a future
version in a meaningful manner. Is it OK to edit the wiki to add one's
opinions?

And in this case, personally I'm not sure why people are talking about
code *breakage*, which is a big word IMO. It's after all removing or
adding @ in a few cases. It's relatively straightforward a fix to
automate. If there can be a dfix to relocate the const from before to
after the function name, then this should be much easier, no? It
wouldn't even need a D3, but could be done in a future D2 point
release. And as someone else said, there's a difference between
outright breakage and planned deprecation.

As for the cases when serious changes to the grammar are needed, I
feel the Py2 to Py3 transition is a good example to emulate. Lots of
cleanup happened in Py3, Py2 is still supported, and there exists
tools like 2to3 and six (https://pypi.python.org/pypi/six) to help
people bridge the gap.

Finally in general I'd also like to suggest that rather than saying
something like "you won't be able to convince Walter of this because
it's not important", which IMHO tends to somewhat put off newbies who
are excited by the language and want to contribute, and tends to put
the project masters in an autocratic light (which people won't like to
hear), one might consider saying something like "D 2 is now aiming for
stability so we are trying to minimize the number of grammar changes".

Thanks again, all!

-- 
Shriramana Sharma ஶ்ரீரமணஶர்மா श्रीरमणशर्मा



More information about the Digitalmars-d-learn mailing list