Beispiel #1
0
        public static MethodInfo CacheFunc <T0, T1, T2, T3, T4, T5, T6, T7, T8, TRet>(Func <T0, T1, T2, T3, T4, T5, T6, T7, T8, TRet> method)
        {
            var info = method.GetMethodInfo();

            lock (_cache) {
                _cache[info] = new FuncCallInstruction <T0, T1, T2, T3, T4, T5, T6, T7, T8, TRet>(method);
            }
            return(info);
        }
Beispiel #2
0
        public static MethodInfo CacheFunc <TRet>(Func <TRet> method)
        {
            var info = method.GetMethodInfo();

            lock (_cache) {
                _cache[info] = new FuncCallInstruction <TRet>(method);
            }
            return(info);
        }