[Mono-bugs] [Bug 78435][Wis] Changed - gmcs and IComparable<T> silliness

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Fri May 19 03:06:02 EDT 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 adrinael at adrinael.net.

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

--- shadow/78435	2006-05-18 04:31:51.000000000 -0400
+++ shadow/78435.tmp.22262	2006-05-19 03:06:02.000000000 -0400
@@ -1,14 +1,14 @@
 Bug#: 78435
 Product: Mono: Compilers
 Version: unspecified
-OS: 
+OS: unknown
 OS Details: 
 Status: NEW   
 Resolution: 
-Severity: 
+Severity: Unknown
 Priority: Wishlist
 Component: C#
 AssignedTo: rharinath at novell.com                            
 ReportedBy: adrinael at adrinael.net               
 QAContact: mono-bugs at ximian.com
 TargetMilestone: ---
@@ -78,6 +78,29 @@
 `System.IComparable<K,V>.CompareTo(K)' has some invalid arguments
 compare.cs(39,10): error CS1503: Argument 1: Cannot convert from `V' to `K'
 
 (Difference: IComparable<K,V>)
 
 o_O
+
+------- Additional Comments From adrinael at adrinael.net  2006-05-19 03:06 -------
+I changed the class to
+
+class foo<I, J, K, L, M, N, V> : IEnumerable<V>
+  where V : IComparable<V>
+{
+ ...
+}
+
+And guess what?
+
+compare.cs(39,10): error CS1502: The best overloaded method match for
+`System.IComparable<I,J,K,L,M,N,V>.CompareTo(I)' has some invalid
+arguments
+compare.cs(39,10): error CS1503: Argument 1: Cannot convert from `V'
+to `I'
+
+The generic parameter list in the constraint is lost and instead the
+parameter list from the class is used!
+
+I warn you, I soon have this bug fixed =P
+


More information about the mono-bugs mailing list