home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / sys / mac / programm / 14862 < prev    next >
Encoding:
Internet Message Format  |  1992-09-01  |  1.5 KB

  1. Path: sparky!uunet!stanford.edu!rutgers!news.columbia.edu!cunixa.cc.columbia.edu!sll2
  2. From: sll2@cunixa.cc.columbia.edu (Steven L Levitt)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: Bad Floating Point bug in Think C 5.0
  5. Message-ID: <1992Sep1.212923.24833@news.columbia.edu>
  6. Date: 1 Sep 92 21:29:23 GMT
  7. Sender: usenet@news.columbia.edu (The Network News)
  8. Distribution: na
  9. Organization: Columbia University
  10. Lines: 23
  11. Nntp-Posting-Host: cunixa.cc.columbia.edu
  12.  
  13. HEELLLLLLLPPPPP!
  14.  
  15. I just moved a fairly large Think C 5.0 project from a Mac II running system
  16. 6.0.4 (very old, I know) to a Mac IIci running system 7.0.1.  Both macchine
  17. were running the same version of Think C, 5.0.2.
  18.  
  19. I have begun to encounter a problem when one of my functions returns a value
  20. of type double (I have the Native Floating Point option on).  Typically, 
  21. the value should be between 100 and -100, yet when the value is printed out
  22. in a window it is always 0.0.  Now, here's the funny part.  When I use the
  23. source-level debugger to set a breakpoint at the line where the function
  24. returns and then step past it, the value is correct, and eventually prints
  25. correctly on the screen.  The only difference is that a breakpoint was set, 
  26. and the program stopped just before the function executed.
  27.  
  28. Could some wise and wonderful person enlighten me as to just what the hell is
  29. going on here?  Does anyone know of incompatabilities Think C has with System
  30. 7 that might cause this?  Thanks in advance.
  31.  
  32.  
  33. ----------------
  34. Steven L. Levitt  sll2@cunixa.cc.columbia.edu
  35. An Undergrad
  36.