[Issue 1053] Make 'static else if' or 'static if (...) {...} else if' work

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Mar 12 16:36:04 PDT 2007


http://d.puremagic.com/issues/show_bug.cgi?id=1053





------- Comment #2 from wbaxter at gmail.com  2007-03-12 18:35 -------
(For the record, there was some discussion on this on the newsgroup Frits'
message above was in reply to something there about which languages use an
'elseif' keyword).

Anyway, I can see the difficulties involved in the implementation of this, but
I still think it would make D better for users.  In the end, it's just an
enhancement request.  If Walter agrees then maybe something will be done about
it, if not then he'll close it.

But here's another attempt to sell the idea: I'm pretty sure there are very few
C/C++/D/Java users who really think of 

if () {
}
else if () {
}
else if () {
}
else () {
}

as this:

if () {
}
else {
   if () {
   }
   else {
       if () {
       }
       else () {
       }
   }
}

which is pretty much the way you have to be thinking for 'else static if' to
make sense.


-- 



More information about the Digitalmars-d-bugs mailing list