home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / gnu / g / lib / bug / 761 < prev    next >
Encoding:
Text File  |  1993-01-08  |  1.1 KB  |  40 lines

  1. Newsgroups: gnu.g++.lib.bug
  2. Path: sparky!uunet!cis.ohio-state.edu!mpi-sb.mpg.de!stefan
  3. From: stefan@mpi-sb.mpg.de (Stefan Naeher)
  4. Subject: Bug in Rational class of g++-2.3
  5. Message-ID: <23686@sbsvax.cs.uni-sb.de>
  6. Sender: gnulists@ai.mit.edu
  7. Reply-To: stefan@mpi-sb.mpg.de
  8. Organization: Max-Planck Institut fuer Informatik
  9. Distribution: gnu
  10. Date: Fri, 8 Jan 1993 11:49:31 GMT
  11. Approved: bug-lib-g++@prep.ai.mit.edu
  12. Lines: 26
  13.  
  14. Class Rational seems to have problems with zero values, e.g., the following 
  15. program exits with the error message "Rational Error: Zero denominator"
  16.  
  17.  
  18. #include <Rational.h>
  19.  
  20. main()
  21. {
  22.   Rational r1 = 17;
  23.  
  24.   Rational r = r1 - 0;
  25. }
  26.  
  27. Is this a known bug, can it be fixed easily ?
  28.  
  29.  
  30. -------------------------------------------------------------------------------
  31. Stefan N"aher                                      e-mail: stefan@mpi-sb.mpg.de
  32. Max-Planck-Institut f"ur Informatik                phone:  +49 681 302 5420
  33. Im Stadtwald                                       fax:    +49 681 302 5401
  34. 6600 Saarbr"ucken
  35. Germany
  36. -------------------------------------------------------------------------------
  37.  
  38.  
  39.  
  40.