Example #1
0
        protected void EmitArgsThis(ZCMethodInfo zdesc, List <Exp> expArgs)
        {
            var        paramArr   = zdesc.ZParams;
            List <Exp> expArgsNew = CallAjuster.AdjustExps(paramArr, expArgs);

            EmitArgsExp(paramArr, expArgs.ToArray());
        }
Example #2
0
 public ExpCallThis(ContextExp context, ZMethodCall expProcDesc, ZCMethodInfo searchedMethod, Exp srcExp, List <Exp> argExps) : base(context)
 {
     this.ExpProcDesc = expProcDesc;
     this.ZMethod     = searchedMethod;
     this.SrcExp      = srcExp;
     this.ArgExps     = argExps;
 }
Example #3
0
        public ContextMethod(ContextClass classContext) : base(classContext)
        {
            ZCClassInfo cclass = this.ClassContext.GetZCompilingType();

            ZMethodInfo = new ZCMethodInfo(cclass);
            cclass.AddMethod(ZMethodInfo);
        }
Example #4
0
 public override Exp Analy()
 {
     if (this.IsAnalyed)
     {
         return(this);
     }
     ZMethod   = SearchZMethod();
     RetType   = ZMethod.RetZType;
     IsAnalyed = true;
     return(this);
 }
Example #5
0
 public override Exp Analy()
 {
     if (this.IsAnalyed)
     {
         return(this);
     }
     VarName   = VarToken.Text;
     Method    = SearchZMethod(VarName);
     RetType   = Method.RetZType;
     IsAnalyed = true;
     return(this);
 }
Example #6
0
 private Exp SearchThis( )
 {
     ZCMethodInfo[] descArray = this.ExpContext.ClassContext.SearchThisProc(CallDesc);
     if (descArray.Length == 0)
     {
         return(null);
     }
     else if (descArray.Length > 1)
     {
         Errorf(this.Position, "找到多个过程,不能确定是属于哪一个简略使用的类型的过程");
         return(null);
     }
     else
     {
         ZCMethodInfo method      = descArray[0];
         ExpCallThis  expCallThis = new ExpCallThis(this.ExpContext, CallDesc, method, this, ArgExps);
         return(expCallThis);
     }
 }
Example #7
0
 private void ImportZMethod(ZCMethodInfo zmethodInfo)
 {
     ImportZDesc(zmethodInfo.ZMethodDesc);
 }