[Mono-devel-list] Re: [Mono-patches] r45553 - trunk/mcs/class/corlib/System.Reflection
Hi, please do not commit such patches to corlib without first testing them. There is an open bug report (#75136) about this issue, but we can't just keep the build broken until that's fixed. Thanks, Martin On Mon, 2005-06-06 at 20:14 -0400, Carlos Alberto Cortes wrote: Author: calberto Date: 2005-06-06 20:14:13 -0400 (Mon, 06 Jun 2005) New Revision: 45553 Modified: trunk/mcs/class/corlib/System.Reflection/ChangeLog trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs trunk/mcs/class/corlib/System.Reflection/CustomAttributeNamedArgument.cs trunk/mcs/class/corlib/System.Reflection/CustomAttributeTypedArgument.cs Log: 2005-06-07 Carlos Alberto Cortez [EMAIL PROTECTED] * CustomAttributeData.cs: Implemented. * CustomAttributeDataNamedArgument.cs: Implemented. * CustomAttrbuteDataTypedArgument.cs: Implemented. Modified: trunk/mcs/class/corlib/System.Reflection/ChangeLog === --- trunk/mcs/class/corlib/System.Reflection/ChangeLog2005-06-07 00:12:21 UTC (rev 45552) +++ trunk/mcs/class/corlib/System.Reflection/ChangeLog2005-06-07 00:14:13 UTC (rev 45553) @@ -1,3 +1,11 @@ +2005-06-07 Carlos Alberto Cortez [EMAIL PROTECTED] + + * CustomAttributeData.cs: Implemented. + + * CustomAttributeDataNamedArgument.cs: Implemented. + + * CustomAttrbuteDataTypedArgument.cs: Implemented. + 2005-06-06 Zoltan Varga [EMAIL PROTECTED] * Assembly.cs ExceptionHandlingClause.cs: Fix build. Modified: trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs === --- trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs 2005-06-07 00:12:21 UTC (rev 45552) +++ trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs 2005-06-07 00:14:13 UTC (rev 45553) @@ -3,6 +3,7 @@ // // Author: // Zoltan Varga ([EMAIL PROTECTED]) +// Carlos Alberto Cortez ([EMAIL PROTECTED]) // // Copyright (C) 2004 Novell, Inc (http://www.novell.com) // @@ -32,6 +33,7 @@ using System.Collections.Generic; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; +using System.Text; namespace System.Reflection { @@ -39,47 +41,87 @@ [ComVisible (true)] #endif public sealed class CustomAttributeData { + ConstructorInfo ctorInfo; + IListCustomAttributeTypedArgument ctorArgs; + IListCustomAttributeNamedArgument namedArgs; - [MonoTODO] + internal CustomAttributeData (ConstructorInfo ctorInfo, object [] ctorArgs, object [] namedArgs) + { + this.ctorInfo = ctorInfo; + + this.ctorArgs = Array.AsReadOnlyCustomAttributeTypedArgument + (ctorArgs != null ? UnboxValuesCustomAttributeTypedArgument (ctorArgs) : new CustomAttributeTypedArgument [0]); + + this.namedArgs = Array.AsReadOnlyCustomAttributeNamedArgument + (namedArgs != null ? UnboxValuesCustomAttributeNamedArgument (namedArgs) : new CustomAttributeNamedArgument [0]); + } + public ConstructorInfo Constructor { get { - throw new NotImplementedException (); + return ctorInfo; } } - [MonoTODO] public IListCustomAttributeTypedArgument ConstructorArguments { get { - throw new NotImplementedException (); + return ctorArgs; } } - [MonoTODO] public IListCustomAttributeNamedArgument NamedArguments { get { - throw new NotImplementedException (); + return namedArgs; } } - [MonoTODO] - public static IListCustomAttributeData GetCustomAttributes (Assembly yarget) { - throw new NotImplementedException (); + public static IListCustomAttributeData GetCustomAttributes (Assembly target) { + return MonoCustomAttrs.GetCustomAttributesData (target); } - [MonoTODO] public static IListCustomAttributeData GetCustomAttributes (MemberInfo target) { - throw new NotImplementedException (); + return MonoCustomAttrs.GetCustomAttributesData (target); } - [MonoTODO] public static IListCustomAttributeData GetCustomAttributes (Module target) { -
Re: [Mono-devel-list] Re: [Mono-patches] r45553 - trunk/mcs/class/corlib/System.Reflection
Hey Martin, thanks for the info. I will try to commit this patch when the problem is fixed. Carlos. El mar, 07-06-2005 a las 05:37 +0200, Martin Baulig escribi: Hi, please do not commit such patches to corlib without first testing them. There is an open bug report (#75136) about this issue, but we can't just keep the build broken until that's fixed. Thanks, Martin On Mon, 2005-06-06 at 20:14 -0400, Carlos Alberto Cortes wrote: Author: calberto Date: 2005-06-06 20:14:13 -0400 (Mon, 06 Jun 2005) New Revision: 45553 Modified: trunk/mcs/class/corlib/System.Reflection/ChangeLog trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs trunk/mcs/class/corlib/System.Reflection/CustomAttributeNamedArgument.cs trunk/mcs/class/corlib/System.Reflection/CustomAttributeTypedArgument.cs Log: 2005-06-07 Carlos Alberto Cortez [EMAIL PROTECTED] * CustomAttributeData.cs: Implemented. * CustomAttributeDataNamedArgument.cs: Implemented. * CustomAttrbuteDataTypedArgument.cs: Implemented. Modified: trunk/mcs/class/corlib/System.Reflection/ChangeLog === --- trunk/mcs/class/corlib/System.Reflection/ChangeLog 2005-06-07 00:12:21 UTC (rev 45552) +++ trunk/mcs/class/corlib/System.Reflection/ChangeLog 2005-06-07 00:14:13 UTC (rev 45553) @@ -1,3 +1,11 @@ +2005-06-07 Carlos Alberto Cortez [EMAIL PROTECTED] + + * CustomAttributeData.cs: Implemented. + + * CustomAttributeDataNamedArgument.cs: Implemented. + + * CustomAttrbuteDataTypedArgument.cs: Implemented. + 2005-06-06 Zoltan Varga [EMAIL PROTECTED] * Assembly.cs ExceptionHandlingClause.cs: Fix build. Modified: trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs === --- trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs 2005-06-07 00:12:21 UTC (rev 45552) +++ trunk/mcs/class/corlib/System.Reflection/CustomAttributeData.cs 2005-06-07 00:14:13 UTC (rev 45553) @@ -3,6 +3,7 @@ // // Author: // Zoltan Varga ([EMAIL PROTECTED]) +// Carlos Alberto Cortez ([EMAIL PROTECTED]) // // Copyright (C) 2004 Novell, Inc (http://www.novell.com) // @@ -32,6 +33,7 @@ using System.Collections.Generic; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; +using System.Text; namespace System.Reflection { @@ -39,47 +41,87 @@ [ComVisible (true)] #endif public sealed class CustomAttributeData { + ConstructorInfo ctorInfo; + IListCustomAttributeTypedArgument ctorArgs; + IListCustomAttributeNamedArgument namedArgs; - [MonoTODO] + internal CustomAttributeData (ConstructorInfo ctorInfo, object [] ctorArgs, object [] namedArgs) + { + this.ctorInfo = ctorInfo; + + this.ctorArgs = Array.AsReadOnlyCustomAttributeTypedArgument + (ctorArgs != null ? UnboxValuesCustomAttributeTypedArgument (ctorArgs) : new CustomAttributeTypedArgument [0]); + + this.namedArgs = Array.AsReadOnlyCustomAttributeNamedArgument + (namedArgs != null ? UnboxValuesCustomAttributeNamedArgument (namedArgs) : new CustomAttributeNamedArgument [0]); + } + public ConstructorInfo Constructor { get { - throw new NotImplementedException (); + return ctorInfo; } } - [MonoTODO] public IListCustomAttributeTypedArgument ConstructorArguments { get { - throw new NotImplementedException (); + return ctorArgs; } } - [MonoTODO] public IListCustomAttributeNamedArgument NamedArguments { get { - throw new NotImplementedException (); + return namedArgs; } } - [MonoTODO] - public static IListCustomAttributeData GetCustomAttributes (Assembly yarget) { - throw new NotImplementedException (); + public static IListCustomAttributeData GetCustomAttributes (Assembly target) { + return MonoCustomAttrs.GetCustomAttributesData (target); } - [MonoTODO] public static IListCustomAttributeData GetCustomAttributes (MemberInfo target) { - throw new NotImplementedException (); + return