home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.os2.programmer
- Path: sparky!uunet!weyrich!orville
- From: orville%weyrich@uunet.uu.net (Orville R. Weyrich)
- Subject: Re: I want NaN and Inf to crash program. Is this possible?
- Message-ID: <1992Nov22.073943.2912@weyrich.UUCP>
- Sender: orville@weyrich.UUCP (Orville R. Weyrich)
- Reply-To: uunet.uu.net!weyrich!orville
- Organization: Weyrich Computer Consulting
- References: <1emagvINNclf@gap.caltech.edu>
- Date: Sun, 22 Nov 92 07:39:43 GMT
- Lines: 19
-
- In article <1emagvINNclf@gap.caltech.edu> brooke@cco.caltech.edu (Brooke Paul Anderson) writes:
- >I want my programs to crash if some operation results in NaN or Inf.
- >Is it possible for me to do this or for me to set some sort of trap?
- >I don't know why gcc is set up so that it continues execution when a
- >NaN or Inf shows up -- this is a real pain in the ass.
-
- I at least prefer it that way -- it allows incomplete information to be
- propagated when that makes sense; the programmer can test for normal
- numerics at strategic points in the program and if need be shut the program
- down gracefully.
-
- orville
-
- -------------------------------------- **************************************
- Orville R. Weyrich, Jr. Weyrich Computer Consulting
- Certified Data Processor POB 5782, Scottsdale, AZ 85261
- Certified Systems Professional Voice: (602) 391-0821
- Certified Computer Programmer Internet: orville%weyrich@uunet.uu.net
- -------------------------------------- **************************************
-