public void EmitGet( ) { MethodInfo getMethod = Property.GetGetMethod(); SubjectExp.Emit(); ArgExp.RequireType = ZTypeManager.GetBySharpType(getMethod.ReturnType) as ZType; ArgExp.Emit(); EmitHelper.CallDynamic(IL, getMethod); }
public void EmitSet(Exp valueExp) { MethodInfo setMethod = Property.GetSetMethod(); SubjectExp.Emit(); ArgExp.RequireType = ZTypeManager.GetBySharpType(setMethod.GetParameters()[0].ParameterType) as ZType; ArgExp.Emit(); //EmitHelper.Box(il, ArgExp.RetType, setMethod.GetParameters()[0].ParameterType); valueExp.RequireType = ZTypeManager.GetBySharpType(setMethod.GetParameters()[1].ParameterType) as ZType; valueExp.Emit(); EmitHelper.CallDynamic(IL, setMethod); }
public override void SetParent(Exp parentExp) { ParentExp = parentExp; SubjectExp.SetParent(this); ArgExp.SetParent(this); }
public override string ToString() { return(string.Format("{0}第{1}", SubjectExp.ToString(), ArgExp.ToString())); }