コード例 #1
0
ファイル: PhpBaseVisitor.cs プロジェクト: yekainew/cs2php
 protected virtual T VisitPhpMethodInvokeValue(PhpMethodInvokeValue node)
 {
     if (ThrowNotImplementedException)
     {
         throw new NotImplementedException(string.Format("Method {0} is not supported in class {1}", "VisitPhpMethodInvokeValue", this.GetType().FullName));
     }
     return(default(T));
 }
コード例 #2
0
        protected override IPhpValue VisitFunctionArgument(FunctionArgument src)
        {
            var expression = TransValue(src.MyValue);
            var a          = expression.GetPhpCode(null);
            var result     = new PhpMethodInvokeValue(expression);

            if (!string.IsNullOrEmpty(src.RefOrOutKeyword))
            {
                result.ByRef = true;
            }
            return(SimplifyPhpExpression(result));
        }
コード例 #3
0
        protected override IPhpValue VisitPhpMethodInvokeValue(PhpMethodInvokeValue node)
        {
            var nv = strip(node.Expression);

            if (PhpSourceBase.EqualCode(nv, node.Expression))
            {
                return(node);
            }
            return(new PhpMethodInvokeValue(nv)
            {
                ByRef = node.ByRef
            });
        }
コード例 #4
0
        public PhpMethodInvokeValue TransFunctionArgument(FunctionArgument a)
        {
            var r = new PhpMethodInvokeValue(TransValue(a.MyValue));

            return(r);
        }