static this
Chris Miller
chris at dprogramming.com
Fri Oct 6 05:14:36 PDT 2006
On Fri, 06 Oct 2006 07:30:18 -0400, Max Samuha <maxter at i.com.ua> wrote:
> Then the compiler should definitely disallow 'this' in a static block
> giving a good compile time error message?
>
>>>
>>> 2. Why module constructor must be attributed with static? All module
>>> level methods are already static so the attribute seems to be
>>> redundant. Make it optional?
>>
>> I guess you're right; my suggestion was to rename main() to this() :)
>
> There may be 'this' in different modules. How the entry point would be
> determined then? Or please give me a link to the thread where your
> suggestion was discussed.
There would only be one module-level 'this', the rest would be 'static
this'.
More information about the Digitalmars-d
mailing list