[Mono-bugs] [Bug 75092][Wis] New - Strange Generic Bug
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Sun May 29 21:26:46 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 spigaz at gmail.com.
http://bugzilla.ximian.com/show_bug.cgi?id=75092
--- shadow/75092 2005-05-29 21:26:46.000000000 -0400
+++ shadow/75092.tmp.31113 2005-05-29 21:26:46.000000000 -0400
@@ -0,0 +1,74 @@
+Bug#: 75092
+Product: Mono: Compilers
+Version: 1.1
+OS:
+OS Details: Gentoo 2.6.11
+Status: NEW
+Resolution:
+Severity:
+Priority: Wishlist
+Component: C#
+AssignedTo: mono-bugs at ximian.com
+ReportedBy: spigaz at gmail.com
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: Strange Generic Bug
+
+Description of Problem:
+In a strange configuration for some unknow reason, gmcs can't find the
+Delegate defined in a generic type.
+
+Steps to reproduce the problem:
+1. Insert into a file and compile it as an assembly:
+public class Generic<T>
+
+{
+ public delegate void Delegate(Generic<T> proxy, T value);
+
+}
+
+public class Class
+{
+ public Generic<bool> Property
+ {
+ get
+ {
+ return null;
+ }
+ }
+ public enum Enum
+ {
+ }
+}
+
+2. Insert into another file and compile it to an exe with the other
+assembly as reference:
+public interface Interface
+{
+ void Add(Class.Enum xBehavior);
+}
+public abstract class Class2
+{
+ public Class2()
+ {
+ }
+ public static void Main()
+ {
+ System.Console.WriteLine(typeof(Generic<bool>.Delegate));
+ }
+}
+
+Actual Results:
+error CS0234: The type name `Delegate' could not be found in type
+`Generic`1<T><System.Boolean>'
+
+Expected Results:
+Generic`1+Delegate<System.Boolean>
+
+How often does this happen?
+Always
+
+Additional Information:
+If the assembly definition is deleted it works fine.
More information about the mono-bugs
mailing list