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=81797 --- shadow/81797 2007-06-01 13:24:09.000000000 -0400 +++ shadow/81797.tmp.11599 2007-06-01 13:24:09.000000000 -0400 @@ -0,0 +1,64 @@ +Bug#: 81797 +Product: Mono: Class Libraries +Version: 1.0 +OS: other +OS Details: +Status: NEW +Resolution: +Severity: +Priority: Normal +Component: CORLIB +AssignedTo: [EMAIL PROTECTED] +ReportedBy: [EMAIL PROTECTED] +QAContact: [EMAIL PROTECTED] +TargetMilestone: --- +URL: +Cc: +Summary: Attribute.GetCustomAttributes doesn't get inherited attributes for properties + +Repro: + +using System.Reflection; +using System; +using System.ComponentModel; + +class b +{ + static void Main () + { + Type derived = typeof (Derived); + PropertyInfo p = derived.GetProperty ("P"); + + Console.WriteLine (p.GetCustomAttributes (true).Length); + Console.WriteLine (Attribute.GetCustomAttributes (p, +true).Length); + } + class Base + { + [DesignOnly (true)] + [Browsable (false)] + [Description ("Desc")] + [Category ("A")] + public virtual string P { + get { return null; } + set { } + } + } + + class Derived : Base + { + public override string P { + get { return null; } + set { } + } + } + +} + +MS prints: +0 +4 + +Mono prints: +0 +0 _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
