[Mono-bugs] [Bug 25658] New - Type.GetTypeCode (typeof (object)) returns TypeCode.Empty

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
2 Jun 2002 05:17:48 -0000


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 duncan@ximian.com.

http://bugzilla.ximian.com/show_bug.cgi?id=25658

--- shadow/25658	Sun Jun  2 01:17:48 2002
+++ shadow/25658.tmp.20926	Sun Jun  2 01:17:48 2002
@@ -0,0 +1,49 @@
+Bug#: 25658
+Product: Mono/Runtime
+Version: unspecified
+OS: other
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: Unknown
+Priority: Major
+Component: misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: duncan@ximian.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Type.GetTypeCode (typeof (object)) returns TypeCode.Empty
+
+Please fill in this template when reporting a bug, unless you know what you
+are doing.
+Description of Problem:
+Type.GetTypeCode (object) returns TypeCode.Empty, instead of TypeCode.Object.
+
+
+Actual Results:
+<duncan@diphthong: ~/ > mono ./typecode.exe 
+Normal: Empty
+Using Convert: Empty
+RESULT: 0
+
+Expected Results:
+<Duncan Mak@FRICATIVE: ~/ > typecode.exe
+Normal: Object
+Using Convert: Object
+
+Additional Information:
+This is the test case
+
+using System;
+
+class X {
+   
+   static void Main ()
+   {	   
+	   object o = new object ();
+	   Console.WriteLine ("Normal: " + Type.GetTypeCode (o.GetType ()));
+	   Console.WriteLine ("Using Convert: " + Convert.GetTypeCode (o));
+   }
+}