Xref: utzoo comp.lang.c:11520 comp.arch:5717 Newsgroups: comp.lang.c,comp.arch Path: utzoo!henry From: henry@utzoo.uucp (Henry Spencer) Subject: compiler detection of potential run-time errors Message-ID: <1988Jul27.202049.21589@utzoo.uucp> Organization: U of Toronto Zoology References: <1988Jul23.221743.22169@utzoo.uucp> <477@m3.mfci.UUCP> <1075@garth.UUCP> Date: Wed, 27 Jul 88 20:20:49 GMT In article <1075@garth.UUCP> smryan@garth.UUCP (Steven Ryan) writes: >Depends on whether all possible programs (including those of monkey >programmers) or just `practical' programs are considerred. Formal proofs >of all possible programs are impossible, flat out, no appeal. Formal proofs >of practical programs depend on how powerful practical has to be to remain >useful. My standing comment on this one is "programmers do not write arbitrary programs". I have no objection to monkey programmers being told "this program is so poorly written that verifying the absence of run-time errors is beyond this compiler's ability". In fact, I have no objection to real programmers occasionally getting the same message, provided some attempt is made to identify the source of the problem. As it is, I occasionally have to modify my programs to keep less-than-perfect implementations of cc or lint happy; an absence-of-run-time-errors checker that required "unnecessary" changes once in a while would still be worth having. (I also wonder whether proving absence of run-time errors is sufficiently weaker than proving correctness that it is fundamentally easier, but on reflection it seems to me that in the [irrelevant] general case it is probably equivalent to the halting problem.) -- MSDOS is not dead, it just | Henry Spencer at U of Toronto Zoology smells that way. | uunet!mnetor!utzoo!henry henry@zoo.toronto.edu