internal FastMethod(ConstructorInfo method, bool doNotCreate = false) { parameters = method.GetParameters(); this.method = method; #if NET472 || NETCOREAPP2_1 fastMethod = EmitHelper.CreateMethodHandler(method, doNotCreate); #endif }
/// <summary> /// Construct a new <see cref="FastMethod"/> associated with an existing method. /// </summary> /// <param name="method">The method.</param> /// <remarks>the constructor is kept private as the FastMethod constructor itself is expensive and instance MUST be cached for performance improvement</remarks> internal FastMethod(MethodBase method) { parameters = method.GetParameters(); this.method = method; #if NET472 || NETCOREAPP2_1 fastMethod = EmitHelper.CreateMethodHandler(method); #endif }
internal FastMethod(ConstructorInfo method, bool doNotCreate = false) { parameters = method.GetParameters(); this.method = method; #if __NET__ || __NETCORE__ fastMethod = EmitHelper.CreateMethodHandler(method, doNotCreate); #else #endif }
/// <summary> /// Construct a new <see cref="FastMethod"/> associated with an existing method. /// </summary> /// <param name="method">The method.</param> /// <remarks>the constructor is kept private as the FastMethod constructor itself is expensive and instance MUST be cached for performance improvement</remarks> internal FastMethod(MethodBase method) { parameters = method.GetParameters(); this.method = method; #if __NET__ || __NETCORE__ fastMethod = EmitHelper.CreateMethodHandler(method); #else #endif }