dotgnu-pnet
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pnet-developers] [bugs #8148] division broken in System.Decimal


From: Gopal.V
Subject: [Pnet-developers] [bugs #8148] division broken in System.Decimal
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; rv:1.7.3) Gecko/20041001 Firefox/0.10.1

This mail is an automated notification from the bugs tracker
 of the project: DotGNU Portable.NET.




/**************************************************************************/
[bugs #8148] Full Item Snapshot:

URL: <http://savannah.gnu.org/bugs/?func=detailitem&item_id=8148>
Project: DotGNU Portable.NET
Submitted by: 0
On: Mon 03/15/2004 at 14:08

Category:  None
Severity:  5 - Average
Item Group:  None
Resolution:  None
Privacy:  Public
Assigned to:  None
Status:  Open


Summary:  division broken in System.Decimal

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. 





Follow-up Comments
------------------


-------------------------------------------------------
Date: Tue 10/26/2004 at 06:20       By: Klaus Treichel <ktreichel>
I have attached a patch to fix the division.






File Attachments
-------------------

-------------------------------------------------------
Date: Tue 10/26/2004 at 09:27  Name: decimal.tgz  Size: 899B   By: t3rmin4t0r
A regression test case.
http://savannah.gnu.org/bugs/download.php?item_id=8148&amp;item_file_id=1804

-------------------------------------------------------
Date: Tue 10/26/2004 at 06:20  Name: kt-041026.patch  Size: 4.92KB   By: 
ktreichel
patch to fix division
http://savannah.gnu.org/bugs/download.php?item_id=8148&amp;item_file_id=1803

-------------------------------------------------------
Date: Mon 03/15/2004 at 14:08  Name: decimals.cs  Size: 410B   By: None
test case
http://savannah.gnu.org/bugs/download.php?item_id=8148&amp;item_file_id=1116






For detailed info, follow this link:
<http://savannah.gnu.org/bugs/?func=detailitem&item_id=8148>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]