On 06/20/2012 09:52 PM, bearophile wrote:
Alex Rønne Petersen:

The static keyword has no effect on module functions, so 2 and 3 are
equivalent.

This problem is caused by DMD sloppyness regarding its management of
attributes. A serious language  doesn't accept a keyword like "static"
where it has no meaning.

What is a 'serious language'?

interface I{ static int x=2; } // java

It just causes confusion to newbies, and makes
it harder to port D code across future D compilers...

Bye,
bearophile

To be fair, it does not have no meaning. It is simply redundant, because all module scope declarations are implicitly 'static'.

Reply via email to