[Mono-bugs] [Bug 76256][Nor] Changed - UIntPtr should be converted to int

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Tue Jan 17 12:38:00 EST 2006

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 kornelpal at hotmail.com.


--- shadow/76256	2006-01-17 08:34:59.000000000 -0500
+++ shadow/76256.tmp.1641	2006-01-17 12:37:59.000000000 -0500
@@ -1,13 +1,13 @@
 Bug#: 76256
 Product: Mono: Compilers
 Version: unspecified
 OS: All
 OS Details: 
-Status: RESOLVED   
-Resolution: NOTABUG
+Status: REOPENED   
 Severity: Unknown
 Priority: Normal
 Component: C#
 AssignedTo: rharinath at novell.com                            
 ReportedBy: kornelpal at hotmail.com               
 QAContact: mono-bugs at ximian.com
@@ -43,6 +43,25 @@
   int -> ulong -> UIntPtr 
 _cannot_ be performed.
 (Note that there are standard explicit conversions from constants to
 uint and ulong, depending on the value of the constant)
+------- Additional Comments From kornelpal at hotmail.com  2006-01-17 12:37 -------
+MS csc generates the following code:
+  .locals init (int32 V_0,
+           native unsigned int V_1)
+  IL_0000:  ldc.i4.2
+  IL_0001:  stloc.0
+  IL_0002:  ldloc.0
+  IL_0003:  conv.i8
+  IL_0004:  call       native unsigned int [mscorlib]
+System.UIntPtr::op_Explicit(unsigned int64)
+  IL_0009:  stloc.1
+That is int -> ulong -> UIntPtr conversion.
+There are some other undocumented behaviors of C# compiler that are 
+copied from MS csc and I don't think that allowing this conversion 
+breaks anything or produces unreliable code.

More information about the mono-bugs mailing list