On Tuesday, 10 July 2012 at 00:17:12 UTC, Timon Gehr wrote:
I have heard that rumour, but TDPL wisely specifies the
behaviour of
the @property attribute as follows:
'In particular "property" is recognized by the the compiler
and signals the fact that the function bearing such an
attribute must be called without the trailing ().'
That is exactly the behaviour I described.
Note that this sentence includes the notion of _calling a
function_
without the trailing () and it even seems to express that the
trailing
() is usually optional.
No it doesn't. It does have emphasis with 'must' and this likely
comes from D having such a long history of the optional (), but
that does not make this statement include such a notion.
So TDPL actually describes a subset of what I have in mind. (it
seems
to leave out the function = argument case completely.) We should
therefore change where we are headed.
The -property is an implementation of what is to come. I was
never greatly for property but since we have it it should be
fully enforced, otherwise we may as well just drop it.