Template Metaprogramming Made Easy (Huh?)

Rainer Deyke rainerd at eldwood.com
Fri Sep 11 16:06:10 PDT 2009


Nick Sabalausky wrote:
> That's *very* programmer-dependent. It originally took took me all of about 
> a week to get used to semicolons after growing up on basic (and even then it 
> was a very very minor time sink), and now just it takes all of about a split 
> second to press that key. But, any time I use a language that doesn't allow 
> semicolon line endings, I keep sticking them in without even thinking about 
> it. Then the compiler complains, and I have to go back and fix it, and that 
> slows down programming more than just instinctively hitting a key.

If you're going to judge features on the basis of habit, then the best
language is always the language you have been using for the longest time.

I'm not entirely happy with the way Scala handles the division between
statements - Scala's rules seem arbitrary and complex - but semicolons
*are* noise, no matter how habitually I use them and how much time I
waste removing them afterwards.

My preferred rule is this:  If two lines have the same indentation, they
are separate statements.  If the second line is indented further than
the first line, the second line is a continuation of the statement
started in the first line.  Surprisingly, even Python (which already has
significant indentation) doesn't use this simple and obvious rule.


-- 
Rainer Deyke - rainerd at eldwood.com



More information about the Digitalmars-d mailing list