Author: marek
Date: 2007-12-23 09:42:13 -0500 (Sun, 23 Dec 2007)
New Revision: 91834
Added:
trunk/mcs/tests/test-603.cs
Log:
2007-12-23 Marek Safar <[EMAIL PROTECTED]>
A test for bug #346379
Added: trunk/mcs/tests/test-603.cs
===================================================================
--- trunk/mcs/tests/test-603.cs 2007-12-23 14:41:58 UTC (rev 91833)
+++ trunk/mcs/tests/test-603.cs 2007-12-23 14:42:13 UTC (rev 91834)
@@ -0,0 +1,30 @@
+// Compiler options: -unsafe
+
+using System;
+
+namespace ConsoleApplication1
+{
+ public struct Strct
+ {
+ public uint a;
+ public uint b;
+ }
+
+ unsafe class Program
+ {
+ static Strct* ptr = null;
+
+ static int Main ()
+ {
+ Strct* values = ptr;
+ values++;
+ values++;
+
+ long diff = values - ptr;
+ if (diff != 2)
+ return 1;
+
+ return 0;
+ }
+ }
+}
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches