[Mono-bugs] [Bug 74241][Nor] New - MCS doesn't encode attributes on event when attributes are prefixed with "method:"
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Wed, 30 Mar 2005 15:16:08 -0500 (EST)
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 sebastien@ximian.com.
http://bugzilla.ximian.com/show_bug.cgi?id=74241
--- shadow/74241 2005-03-30 15:16:08.000000000 -0500
+++ shadow/74241.tmp.359 2005-03-30 15:16:08.000000000 -0500
@@ -0,0 +1,90 @@
+Bug#: 74241
+Product: Mono: Compilers
+Version: 1.1
+OS: All
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: C#
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: sebastien@ximian.com
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: MCS doesn't encode attributes on event when attributes are prefixed with "method:"
+
+Description of Problem:
+MCS doesn't encode attributes on event when attributes are prefixed with
+"method:"
+
+Steps to reproduce the problem:
+1. Compile this sample with MCS
+
+using System;
+using System.Security.Permissions;
+
+abstract class Abstract {
+
+ [method: SecurityPermission (SecurityAction.LinkDemand,
+ControlDomainPolicy = true)]
+ event EventHandler Event;
+
+}
+
+class Program : Abstract {
+
+ event EventHandler Event {
+ add {;}
+ remove {;}
+ }
+
+ static void Main ()
+ {
+ }
+}
+
+2. Dissassemble the assembly
+
+% monodis --declsec eventmethattr.exe
+
+3. Recompile with sample with CSC (I used 7.1)
+
+4. Dissassemble the assembly
+
+% monodis --declsec eventmethattr.exe
+
+
+Actual Results (MCS):
+% monodis --declsec eventmethattr.exe
+DeclSecurity Table (1..0)
+
+
+Expected Results (CSC):
+% monodis --declsec eventmethattr.exe
+DeclSecurity Table (1..2)
+1: LinkDemand on MethodDef 1:
+ <PermissionSet class="System.Security.PermissionSet"
+ version="1">
+ <IPermission class="System.Security.Permissions.SecurityPermission,
+mscorlib, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
+ version="1"
+ Flags="ControlDomainPolicy"/>
+</PermissionSet>
+
+2: LinkDemand on MethodDef 2:
+ <PermissionSet class="System.Security.PermissionSet"
+ version="1">
+ <IPermission class="System.Security.Permissions.SecurityPermission,
+mscorlib, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
+ version="1"
+ Flags="ControlDomainPolicy"/>
+</PermissionSet>
+
+
+How often does this happen?
+Always
+
+Additional Information: