Article View: comp.std.c
Article #4600Re: Undefined result vs. int's holding undefined values.
From: Henry Spencer
Date: Tue, 09 Jan 1996 19:50
Date: Tue, 09 Jan 1996 19:50
16 lines
1341 bytes
1341 bytes
> Does an appropriate "SAFE TEST" exist >for multiple. Has anyone actually seen a real production program where every >calculation was protected against overflow/underflow. Safe tests exist for all the arithmetic operations, although you have to be careful and clever. See the paper "On Legality Assertions in Euclid", by Dave Wortman in the July 1979 IEEE Transactions on Software Engineering, for a fairly complete discussion of the matter. A program in which overflow/underflow can occur is a buggy program. In most cases, the nature of the program is such that the calculations can be shown not to overflow/underflow. Where this is not so, checks are necessary for a reliable program. -- Look, look, see Windows 95. Buy, lemmings, buy! | Henry Spencer Pay no attention to that cliff ahead... | henry@zoo.toronto.edu
Technical Details
Message-ID:
<DKxJ3K.4u1%spenford@zoo.toronto.edu>Path:
arc1-ca.pugleaf.net!info.physics.utoronto.ca!utzoo!spenford!henryReferences:
<oZA8wQ9ytpjN084yn@csn.net> <4cs460$d6e@news.informix.com> <821155074snz@genesis.demon.co.uk>Show Full Headers
Complete Article Headers
Newsgroups: comp.std.c Path: arc1-ca.pugleaf.net!info.physics.utoronto.ca!utzoo!spenford!henry From: Henry Spencer <henry@zoo.toronto.edu> Subject: Re: Undefined result vs. int's holding undefined values. References: <oZA8wQ9ytpjN084yn@csn.net> <4cs460$d6e@news.informix.com> <821155074snz@genesis.demon.co.uk> Sender: henry%spenford@zoo.toronto.edu (Henry Spencer) Organization: SP Systems, Toronto Date: Tue, 9 Jan 1996 19:50:08 GMT Message-ID: <DKxJ3K.4u1%spenford@zoo.toronto.edu>