const main args?
bearophile
bearophileHUGS at lycos.com
Mon Aug 15 10:33:15 PDT 2011
Steven Schveighoffer:
> int main(string[] _args)
> {
> const args = _args; // not modifiable copy
> }
Currently DMD accepts code like:
int main(in string[] args) { return 0; }
void main(in string[] args) {}
int main() { return 0; }
void main() {}
What I have asked is if it's worth changing D/DMD so it only accepts such two four forms.
> D cannot always be perfect, and I'd rather we
> spend more time on the meaty parts of the language.
The topic of this thread is surely a minor thing, I agree there are far more important things to work on. But on the base of my experience I don't agree with you. Little things are little, but they pile up. Little wrong things don't make a language unusable, but many little things done right reduce programming stress and improve how much you like your language (sometimes they avoid some bugs in your code).
At its base Python is not a big deal, its implementation sucks, it contains no new ideas, and even its basic syntax is like C. But hundreds of well thought out and carefully designed "user-interface" details in the core language and its standard library make its usage pleasurable.
Bye,
bearophile
More information about the Digitalmars-d-learn
mailing list