Digital Mars Website
Timon Gehr
timon.gehr at gmx.ch
Sat Nov 12 13:04:46 PST 2011
On 11/12/2011 09:41 PM, Jude Young wrote:
> On Sat 12 Nov 2011 02:19:21 PM CST, Jeff Nowakowski wrote:
>> On 11/11/2011 05:58 PM, Jude Young wrote:
>>>
>>> I came very close to assuming D was dead and going off to look at
>>> another language. (I was considering Go, But I hate the forced {}
>>> syntax)
>>
>> It's funny, the trivial reasons that people will come up with to
>> choose a programming language.
>>
>
> Please, I'm sure there's worse.
> My real problem with it is that there doesn't seem to be any logical
> reason for it.
The reason is that Go does not require the ()
if i<j {
// do stuff
}
Also
if(i<j) do_stuff();
is the same number of key strokes as
if i<j {do_stuff();}
and if you want to do other stuff, the first has to be changed to
if(i<j){do_stuff(); do_other_stuff();}
and the second to
if i<j {do_stuff(); do_other_stuff() }
Which means the second requires less changes. (unless you abuse the
comma operator.)
More information about the Digitalmars-d
mailing list