@disable

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Fri Jan 15 22:58:36 PST 2010


KennyTM~ wrote:
> On Jan 16, 10 01:01, The Anh Tran wrote:
>> Andrei Alexandrescu wrote:
>>> The main idea is to allow creation of noncopyable types by marking
>>> this(this) as @disable.
>>>
>>> Noncopyable types are pivotal for a number of idioms important in
>>> concurrency and elsewhere.
>>>
>>>
>>> Andrei
>>
>> IMHO, we could extend existing syntax instead of invent new one.
>> I really love the Scale style:
>>
>> Excerpt from Scala reference. Page 59.
>> package outerpkg.innerpkg
>> class Outer
>> {
>> class Inner
>> {
>> private[Outer] def f()
>> private[innerpkg] def g()
>> private[outerpkg] def h()
>> }
>> }
>>
>> http://www.scala-lang.org/sites/default/files/linuxsoft_archives/docu/files/ScalaReference.pdf 
>>
>>
> 
> The @attribute syntax is designed to be used like this. (Although 
> currently they're all keywords in the future you may be able to have 
> @identifier_of_custom_attribute).

I'd also like to see other keywords (nothrow, pure, override come to 
mind) transferred into the attribute space.

Andrei



More information about the Digitalmars-d mailing list