home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.compilers:1549 comp.human-factors:2206
- Path: sparky!uunet!usc!cs.utexas.edu!rutgers!faatcrl!iecc!compilers-sender
- From: weberwu@inf.fu-berlin.de (Debora Weber-Wulff)
- Newsgroups: comp.compilers,comp.human-factors
- Subject: Re: language design tradeoffs
- Keywords: design, parse
- Message-ID: <92-09-068@comp.compilers>
- Date: 13 Sep 92 12:34:30 GMT
- References: <92-09-048@comp.compilers> <92-09-066@comp.compilers>
- Sender: compilers-sender@iecc.cambridge.ma.us
- Reply-To: weberwu@inf.fu-berlin.de (Debora Weber-Wulff)
- Organization: Free University of Berlin
- Lines: 21
- Approved: compilers@iecc.cambridge.ma.us
-
- raveling@Unify.com (Paul Raveling) writes:
- [sick macro trap in C deleted]
-
- >then the extra ';' terminates the entire 'if' statement and the following
- >'else' produces a syntax error. Or if you had left yourself open to the
- >dangling else problem in nested if's, it's possible to get no syntax error
- >but instead to get a surprising flow of control.
-
- Sigh. The problem is not the ';', it's the syntax of the if statement. If
- ';' were nothing more than a statement separator and the empty statement
- were allowed, we could write ';;;;;;;;;;;;;;;;' if we felt like it. Then
- 'if' must be terminated with a nice 'fi'and the problem goes away. Another
- reason why explicit terminators like od and fi are a good idea!
- --
- Debora Weber-Wulff dww@inf.fu-berlin.de
- Institut fuer Informatik +49 30 89691 124
- Nestorstr. 8-9
- D-W-1000 Berlin 31
- --
- Send compilers articles to compilers@iecc.cambridge.ma.us or
- {ima | spdcc | world}!iecc!compilers. Meta-mail to compilers-request.
-