[Mono-bugs] [Bug 52093][Nor] New - vectors need to be different types from arrays with rank == 1
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Fri, 12 Dec 2003 05:43:30 -0500 (EST)
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 lupus@ximian.com.
http://bugzilla.ximian.com/show_bug.cgi?id=52093
--- shadow/52093 2003-12-12 05:43:30.000000000 -0500
+++ shadow/52093.tmp.27170 2003-12-12 05:43:30.000000000 -0500
@@ -0,0 +1,40 @@
+Bug#: 52093
+Product: Mono/Runtime
+Version: unspecified
+OS: other
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: misc
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: lupus@ximian.com
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: vectors need to be different types from arrays with rank == 1
+
+This test case fails in mono.
+
+using System;
+
+class T {
+
+ static int Main () {
+ int[] a = new int [1];
+ int[] b;
+ Array arr = null;
+ bool cast_failed = false;
+ try {
+ arr = Array.CreateInstance (typeof (int), new int[] {1}, new int[] {10});
+ b = (int[])arr;
+ } catch {
+ cast_failed = true;
+ }
+ Console.WriteLine (a.GetType().ToString ());
+ Console.WriteLine (arr.GetType().ToString ());
+ return cast_failed? 0: 1;
+ }
+}