Related articles |
---|
Is the dangling else a syntax bug? vbdis@aol.com (2001-06-28) |
Re: Is the dangling else a syntax bug? ralph@inputplus.demon.co.uk (2001-07-02) |
Re: Is the dangling else a syntax bug? lhp+news@toft-hp.dk (2001-07-03) |
Re: Is the dangling else a syntax bug? vbdis@aol.com (2001-07-03) |
Re: Is the dangling else a syntax bug? ralph@inputplus.demon.co.uk (2001-07-06) |
Re: Is the dangling else a syntax bug? ralph@inputplus.demon.co.uk (2001-07-06) |
Re: Is the dangling else a syntax bug? gsc@zip.com.au (Sean Case) (2001-07-06) |
Re: Is the dangling else a syntax bug? lars@bearnip.com (2001-07-06) |
[18 later articles] |
From: | ralph@inputplus.demon.co.uk (Ralph Corderoy) |
Newsgroups: | comp.compilers |
Date: | 2 Jul 2001 00:35:49 -0400 |
Organization: | InputPlus Ltd. |
References: | 01-06-073 |
Keywords: | parse, design, comment |
Posted-Date: | 02 Jul 2001 00:35:49 EDT |
Hi,
> It was quite surprising to me, that lists with separated items are
> the more natural and economic approach, in contrast to the commonly
> used statement terminators!
In favour of terminators are their similarity to the normal termination
of written English sentances. I don't leave the full stop off the last
sentance in this paragraph.
Also, separators are a pain if appending a new item to the list means
an easily forgotton separator needs to be added.
foo(a, b, c)
foo(a, b, c, d) # not easily forgotton, close by.
u = get_user(id);
update_user(u, change);
print_user(u)
u = get_user(id);
update_user(u, change);
print_user(u) # easily forgotton.
commit_user(u)
Ralph.
[It's a religious argument. Separators are more mathematically elegant,
but terminators match people's expectations better. -John]
Return to the
comp.compilers page.
Search the
comp.compilers archives again.