home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.compilers:1551 comp.human-factors:2216
- Path: sparky!uunet!gatech!rutgers!faatcrl!iecc!compilers-sender
- From: rob@guinness.eng.ohio-state.edu (Rob Carriere)
- Newsgroups: comp.compilers,comp.human-factors
- Subject: Re: language design tradeoffs
- Keywords: design, parse, comment
- Message-ID: <92-09-070@comp.compilers>
- Date: 14 Sep 92 04:43:27 GMT
- References: <92-09-048@comp.compilers> <92-09-068@comp.compilers>
- Sender: compilers-sender@iecc.cambridge.ma.us
- Reply-To: rob@guinness.eng.ohio-state.edu (Rob Carriere)
- Organization: The Ohio State University Dept of Electrical Engineering
- Lines: 28
- Approved: compilers@iecc.cambridge.ma.us
-
- weberwu@inf.fu-berlin.de (Debora
- Weber-Wulff) writes:
- >raveling@Unify.com (Paul Raveling) writes:
- >[sick macro trap in C deleted]
- >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!
-
- True. It is, however, possible to achieve the same effect in languages
- that don't require if/do terminators by religously making the statement
- inside the if/do a block; i.e. always use {} or BEGIN/END or whatever it's
- called in the language of the week.
-
- In fact, I would argue that a language that requires coding that way has
- superior syntax to a do/od language, because of the well-known problem
- with the spelling of the terminators. Things like TNEMMOC, CNUF and NIGEB
- start looking OD rather quickly.
-
- SR
- ---
- [Algol68 came close to TNEMMOC, but also did an amazing job of letting you
- use parentheses, vertical bars, and the like, as synonyms for if, else, fi,
- begin, end, and other common delimiters. -John]
- --
- Send compilers articles to compilers@iecc.cambridge.ma.us or
- {ima | spdcc | world}!iecc!compilers. Meta-mail to compilers-request.
-