[Mono-bugs] [Bug 75540][Maj] New - Decimal throws an exception on CYGWIN

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Wed Jul 13 05:11:55 EDT 2005

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by kostat at mainsoft.com.


--- shadow/75540	2005-07-13 05:11:55.000000000 -0400
+++ shadow/75540.tmp.13600	2005-07-13 05:11:55.000000000 -0400
@@ -0,0 +1,40 @@
+Bug#: 75540
+Product: Mono: Class Libraries
+Version: unspecified
+OS Details: CYGWIN
+Status: NEW   
+Priority: Major
+Component: CORLIB
+AssignedTo: mono-bugs at ximian.com                            
+ReportedBy: kostat at mainsoft.com               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+Summary: Decimal throws an exception on CYGWIN 
+Steps to reproduce the problem:
+1. Run the following code:
+decimal d1 = 0;
+decimal d = d1 / 10000000000000000000000000000M;
+Console.WriteLine( d > 0 );
+decimal d2 = 1;
+decimal d3 = d2 + d;
+Console.WriteLine( d3 ); 
+Actual Results:
+Unhandled Exception: System.OverflowException: Overflow on adding decimal
+in <0x00063> System.Decimal:Add (Decimal d1, Decimal d2)
+in <0x0004a> System.Decimal:op_Addition (Decimal d1, Decimal d2)
+in <0x001e8> Class1:Main (System.String[] args)
+Expected Results:

More information about the mono-bugs mailing list