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 [EMAIL PROTECTED] http://bugzilla.ximian.com/show_bug.cgi?id=77527 --- shadow/77527 2006-02-10 18:57:23.000000000 -0500 +++ shadow/77527.tmp.4849 2006-02-10 18:57:23.000000000 -0500 @@ -0,0 +1,79 @@ +Bug#: 77527 +Product: Mono: Compilers +Version: 1.1 +OS: +OS Details: +Status: NEW +Resolution: +Severity: +Priority: Normal +Component: C# +AssignedTo: [EMAIL PROTECTED] +ReportedBy: [EMAIL PROTECTED] +QAContact: [EMAIL PROTECTED] +TargetMilestone: --- +URL: +Cc: +Summary: [GMCS] Cannot compile generics anonymous method + +Please fill in this template when reporting a bug, unless you know what you +are doing. +Description of Problem: + + +Steps to reproduce the problem: + +using System; +using System.Collections.Generic; +using System.Text; + +namespace A +{ + public class StringEnum + { + public readonly string Value; + readonly string[] aliases; + + protected StringEnum(string v) + { + Value = v; + } + + protected static T Parse<T>(string value, params T[] args) where T +: StringEnum + { + T item = Array.Find<T>(args, delegate(T t) + { + if (t.Value == value) + return true; + + return Array.Exists<string>(t.aliases, delegate (string s) + { + return s == value; + }); + }); + + + if (item == null) + throw new ArgumentOutOfRangeException("value", value); + + return item; + } + } +} + + +Actual Results: + +(19,15): error CS0029: Cannot implicitly convert type `System.Nullable<T +>' to `T' + +Expected Results: + +No error (except CS5001) + +How often does this happen? + +100% + +Additional Information: _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
