X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=mcs%2Fclass%2Fcorlib%2FSystem.Reflection.Emit%2FMonoArrayMethod.cs;h=aa24bc34719719e1a239956278473190950c3331;hb=3673d051fbd6ac16b184f51efcb352cfc4a1481c;hp=68aaedb18324d20554911c3d159b9efd357514ba;hpb=881f83658281916d8f0784df7c726ecb7cc289db;p=mono.git diff --git a/mcs/class/corlib/System.Reflection.Emit/MonoArrayMethod.cs b/mcs/class/corlib/System.Reflection.Emit/MonoArrayMethod.cs index 68aaedb1832..aa24bc34719 100644 --- a/mcs/class/corlib/System.Reflection.Emit/MonoArrayMethod.cs +++ b/mcs/class/corlib/System.Reflection.Emit/MonoArrayMethod.cs @@ -31,13 +31,16 @@ // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // +#if !FULL_AOT_RUNTIME using System; using System.Globalization; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; namespace System.Reflection { + [StructLayout (LayoutKind.Sequential)] internal class MonoArrayMethod: MethodInfo { +#pragma warning disable 649 internal RuntimeMethodHandle mhandle; internal Type parent; internal Type ret; @@ -45,6 +48,7 @@ namespace System.Reflection { internal string name; internal int table_idx; internal CallingConventions call_conv; +#pragma warning restore 649 internal MonoArrayMethod (Type arrayClass, string methodName, CallingConventions callingConvention, Type returnType, Type[] parameterTypes) { name = methodName; @@ -54,7 +58,7 @@ namespace System.Reflection { call_conv = callingConvention; } - [MonoTODO] + [MonoTODO("Always returns this")] public override MethodInfo GetBaseDefinition() { return this; /* FIXME */ } @@ -63,22 +67,35 @@ namespace System.Reflection { return ret; } } - [MonoTODO] + + [MonoTODO("Not implemented. Always returns null")] public override ICustomAttributeProvider ReturnTypeCustomAttributes { get {return null;} } - [MonoTODO] + [MonoTODO("Not implemented. Always returns zero")] public override MethodImplAttributes GetMethodImplementationFlags() { return (MethodImplAttributes)0; } - [MonoTODO] - public override ParameterInfo[] GetParameters() { - return new ParameterInfo [0]; + [MonoTODO("Not implemented. Always returns an empty array")] + public override ParameterInfo[] GetParameters() + { + return GetParametersInternal (); } - [MonoTODO] + internal override ParameterInfo[] GetParametersInternal () + { + return EmptyArray.Value; + } + + [MonoTODO("Not implemented. Always returns 0")] + internal override int GetParametersCount () + { + return 0; + } + + [MonoTODO("Not implemented")] public override Object Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) { throw new NotImplementedException (); } @@ -86,7 +103,8 @@ namespace System.Reflection { public override RuntimeMethodHandle MethodHandle { get {return mhandle;} } - [MonoTODO] + + [MonoTODO("Not implemented. Always returns zero")] public override MethodAttributes Attributes { get { return (MethodAttributes)0; @@ -128,7 +146,11 @@ namespace System.Reflection { parms = parms + ", "; parms = parms + p [i].ParameterType.Name; } - return ReturnType.Name+" "+Name+"("+parms+")"; + if (ReturnType != null) + return ReturnType.Name+" "+Name+"("+parms+")"; + else + return "void "+Name+"("+parms+")"; } } } +#endif