bugDotGNU Portable.NET - Bugs: bug #8148, division broken in System.Decimal

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #8148: division broken in System.Decimal

Submitter:  None
Submitted:  Mon 15 Mar 2004 02:08:56 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed

Tue 26 Oct 2004 02:56:16 PM UTC, comment #3: 

fixed in cvs

Klaus Treichel <ktreichel>
Group administrator
Tue 26 Oct 2004 12:51:01 PM UTC, comment #2: 

The second version. Fixes some silly mistakes.

Klaus Treichel <ktreichel>
Group administrator
Tue 26 Oct 2004 06:20:45 AM UTC, comment #1: 

I have attached a patch to fix the division.

Klaus Treichel <ktreichel>
Group administrator
Mon 15 Mar 2004 02:08:56 PM UTC, original submission:  

The attached program tries to compute 1/7 with the decimal type (1). The result prints as "44834799017975888171469461274". For comparision the 1/7 is also computed via a conversion to double  and a back conversion to decimal (2). The result is 0.1428571428571428315532886016 this time. The result from (1) is then multiplied with 10 (3). This raises a System.OverflowException.




Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files
file #1933:  kt-041026.patch added by ktreichel (5KiB - text/x-patch - next try)
file #1932:  decimal.tgz added by t3rmin4t0r (899B - application/x-compressed - A regression test case.)
file #1931:  kt-041026.patch added by ktreichel (5KiB - text/x-patch - patch to fix division)
file #1135:  decimals.cs added by None (410B - application/octet-stream - test case)

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

 

Follow 6 latest changes.

Date Changed by Updated Field Previous Value => Replaced by
2004-10-26 ktreichel StatusNone Fixed
    Open/ClosedOpen Closed
2004-10-26 ktreichel Attached File- Added kt-041026.patch, #1805
2004-10-26 t3rmin4t0r Attached File- Added decimal.tgz, #1804
2004-10-26 ktreichel Attached File- Added kt-041026.patch, #1803
2004-03-15 None Attached File- Added decimals.cs, #1116

Back to the top

Powered by Savane 3.12