On Monday, 15 October 2012 at 15:22:38 UTC, Andrei Alexandrescu wrote:
<snip>

Yes, this is a nice thing Java, .NET and Python have.

Wonder if a simple convention would suffice, e.g. every module that wanna defines a moduleMain(string[] args) and then you have one module main.d that has:

void main(string[] args) { import wuddever; moduleMain(args); }


Andrei

Great idea! But why add another (redundant) level of indirection?
It should go in the C main in druntime together with a mechanism to call the correct D main, by e.g. reading the module name from the command line.


Reply via email to