home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!gumby!destroyer!terminator!potts
- From: potts@itl.itd.umich.edu (Paul Potts)
- Subject: Re: GOTO, was: Tiny proposal for na
- Message-ID: <1992Sep8.134501.9894@terminator.cc.umich.edu>
- Sender: news@terminator.cc.umich.edu (Usenet Owner)
- Organization: Instructional Technology Laboratory, University of Michigan
- References: <1992Aug27.181013.29933@spss.com> <rmartin.715102882@thor> <1992Aug31.170908.13389@us-es.sel.de>
- Date: Tue, 8 Sep 1992 13:45:01 GMT
- Lines: 37
-
- In article <1992Aug31.170908.13389@us-es.sel.de> kanze@us-es.sel.de (James Kanze) writes:
- >...
- >
- >Apparently most of the responses have been in favor of using break. Do I
- >conclude that most programmers just don't care about having correct programs?
-
- I have been to several talks on the formal verification of programs - it
- still strikes me that for anything more complex than a basic academic
- exercise, it is pointless to attempt such a thing. I agree that it is in
- principle a good idea, expecially, for example, in software used in medical
- devices where an error can be life-threatening. But I am writing code that
- runs under DOS on some arbitrary system, using a class library I didn't write -
- what possible concern could I have for formally verifying my program?
-
- I try to make my code as legible as possible, and try to keep the structure
- as simple as is practicable; I examine my loop invariants, attempt to test
- with a range of possible values, check error codes, and while debugging use
- "assert" tests; but I also will use GOTO on those occasions when it can
- enhance my code, and break. I'm not writing a textbook, I'm writing a program,
- and the real world isn't so ideal as to allow me to argue that my program
- is formally correct (other than letting me mention in passing that the
- compiler doesn't seem to complain).
-
- One man's opinion... can we put this debate to bed soon?
-
- >--
- >James Kanze GABI Software, Sarl.
- >email: kanze@us-es.sel.de 8 rue du Faisan
- > 67000 Strasbourg
- > France
-
-
- --
- "...remove protective cap. Hold atomizer with thumb at base and nozzle
- between first and second fingers. Without tilting head, insert nozzle into
- nostril. Fully depress rim with a firm, even stroke and sniff deeply."
- -advice for presidential candidates from Paul Potts - potts@itl.itd.umich.edu
-