Пример #1
0
        public IInterpetedOperation <IInterpetedAnyType> NextCallOperation(INextCallOperation co)
        {
            var methodType = co.Right.Returns().Cast <IMethodType>();

            var method = GetMethod(new Type[] { TypeMap.MapType(methodType.InputType), TypeMap.MapType(methodType.OutputType) }, nameof(NextCallOperation));

            return(method.Invoke(this, new object[] { co }).Cast <IInterpetedOperation <IInterpetedAnyType> >());
        }
Пример #2
0
 public IInterpetedOperation NextCallOperation(INextCallOperation co)
 {
     if (backing.TryGetValue(co, out var res))
     {
         return(res);
     }
     else
     {
         var op = new InterpetedNextCallOperation();
         backing.Add(co, op);
         op.Init(
             co.Left.Convert(this),
             co.Right.Convert(this));
         return(op);
     }
 }
Пример #3
0
 public IReadOnlyList <IMemberDefinition> NextCallOperation(INextCallOperation co)
 {
     return(Walk(co.Operands));
 }
Пример #4
0
 private IInterpetedOperation <IInterpetedAnyType> NextCallOperation <TIn, TOut>(INextCallOperation co)
     where TIn : class, IInterpetedAnyType
     where TOut : class, IInterpetedAnyType
 {
     if (backing.TryGetValue(co, out var res))
     {
         return(res);
     }
     else
     {
         var op = new InterpetedNextCallOperation <TIn, TOut>();
         backing.Add(co, op);
         op.Init(
             co.Left.Convert(this).Cast <IInterpetedOperation <TIn> >(),
             co.Right.Convert(this).Cast <IInterpetedOperation <IInterpetedCallable <TIn, TOut> > >());
         return(op);
     }
 }
Пример #5
0
 public Nothing NextCallOperation(INextCallOperation co)
 {
     Push(co).Walk(co.Operands);
     return(new Nothing());
 }