Time to rename "D" to "@D" !?

Jacob Carlborg via Digitalmars-d digitalmars-d at puremagic.com
Tue Jun 24 12:32:03 PDT 2014


On 2014-06-23 22:34, Jonathan M Davis via Digitalmars-d wrote:

> It would be very cool if we could remove @ from all of the built-in
> attributes, but the whole reason that they have them in the first place is
> because it was decided that we didn't want to add new keywords - and that was
> several years ago when D had a smaller user base. So, I really don't see it
> changing at this point. If anything, we might go the _other_ way and add @
> onto the attributes that don't have it in order to make them more consistent
> (though I hope that we don't do that, because it's ugly and more verbose).

Since we got UDA's that use the @attribute syntax, the idea of appending 
an @ symbol in front of an attribute to avoid name collisions doesn't 
work anymore.

 From a user point of view, the attributes starting with an @ symbol are 
just as much keywords as those who don't.

> I sympathize with you, but I think that we're stuck at this point.

I we want to minimize name collisions it would be better to remove all 
attributes and only have a single attribute, like this:

@attribute(nothrow, public, const) void foo ();

-- 
/Jacob Carlborg


More information about the Digitalmars-d mailing list