[Mono-bugs] [Bug 75889][Maj] Changed - [GMCS] Wrong 'is' statement execution

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Tue Sep 6 11:03:57 EDT 2005


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 malekith at pld-linux.org.

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

--- shadow/75889	2005-09-06 09:55:27.000000000 -0400
+++ shadow/75889.tmp.4052	2005-09-06 11:03:57.000000000 -0400
@@ -61,6 +61,29 @@
 I'm also interested in this bug, so I added myself to Cc:. I hope it's OK.
 
 ------- Additional Comments From martin at ximian.com  2005-09-06 09:55 -------
 This is a mini bug - in CEE_ISINST, we need to check whether one of
 the types is a generic instance and then use some other comparision
 function (which still needs to be written).
+
+------- Additional Comments From malekith at pld-linux.org  2005-09-06 11:03 -------
+Please note that this special handling is only required in certain
+cases. For example here:
+
+class A<T> { }
+class B<T> : A<T> { }
+
+test (A<int> a) {
+  if (a is B<int>) { ... }
+}
+
+the usual handling is just fine, becasue if we statically know the
+value is of type A<int> and it's B, then it's B<int>.
+
+To be precise the situation is when we know the value is of type T1,
+T2 is subtype of T1 and all generic parameters of T2 are used in
+subtyping declaration of T2, though I would be still happy if only the
+case of T2<p1,...,pn> : T1<p1,...,pn> was handled this faster way.
+
+I'm marking this because this check is performance critical for
+Nemerle code.
+


More information about the mono-bugs mailing list