[Issue 13388] accept '@' before 'nothrow', 'pure', 'final', 'abstract' and 'override'
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Thu Aug 28 23:48:06 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=13388
--- Comment #7 from Ketmar Dark <ketmar at ketmar.no-ip.org> ---
> Just think of the @ as part of the name, and the inconsistency goes away anyway
no, it's not. it's ok to remember *words*, but it's not ok to remember which
word should be prepended with 'sigil'.
it can be ok for attributes with meaningless names. there is really no much
difference between '@riogjheo' and 'riogjheo' — they both sux and hard to
remember. but making some *words* special… why '@safe' needs '@' and 'pure'
don't? what is so special about the word 'pure' (or 'safe')? why should i
remember this nonsence?
ok, we can go another way: strip out all '@' from compiler-defined attributes.
and we can do this without introducing new keywords — just forbid prefix
attributes. so
void foo () system;
will not require "system" to be a keyword, and we can declare and use variables
with the name 'system' in other code.
this patch is little more intrusive, but i can try to write it. do you think
that it will be better alternative to this one?
--
More information about the Digitalmars-d-bugs
mailing list