Esempio n. 1
0
        public static Expression TypeOperatorFunc(
            OpFuncArgs args
            )
        {
            Expression le = args.exprStack.Pop();

            return(((TypeOperator)args.op).func(le, args.t.type));
        }
Esempio n. 2
0
        public static Expression UnaryOperatorFunc(
            OpFuncArgs args
            )
        {
            Expression le = args.exprStack.Pop();

            return(((UnaryOperator)args.op).func(le));
        }
Esempio n. 3
0
        public static Expression BinaryOperatorFunc(
            OpFuncArgs args
            )
        {
            Expression re = args.exprStack.Pop();
            Expression le = args.exprStack.Pop();

            // perform implicit conversion on known types
            TypeConversion.Convert(ref le, ref re);
            return(((BinaryOperator)args.op).func(le, re));
        }
Esempio n. 4
0
        public static Expression MethodOperatorFunc(
            OpFuncArgs args
            )
        {
            //var nextToken = args.literalStack.Pop();
            var        nextToken = ((MemberToken)args.t).name;
            Expression le        = args.exprStack.Pop();

            Expression result = ((MethodOperator)args.op).func(le, nextToken, args.args, args.stack);

            return(result);
        }