//似乎Clone可以替代New系列 public VBox Mod_New(VBox right) { VBox newbox = ValueOnStack.MakeVBox(type); switch (typeStack) { case NumberOnStack.Int32: newbox.v32 = v32 % right.v32; break; case NumberOnStack.Int64: newbox.v64 = v64 % right.v64; break; case NumberOnStack.Double: newbox.vDF = vDF % right.vDF; break; } return(newbox); }
public VBox Clone() { VBox b = ValueOnStack.MakeVBox(this.type); switch (typeStack) { case NumberOnStack.Int32: b.v32 = this.v32; break; case NumberOnStack.Int64: b.v64 = this.v64; break; case NumberOnStack.Double: b.vDF = this.vDF; break; } return(b); }
public static VBox MakeVBox(Type type) { NumberType typeCode = ValueOnStack.GetTypeCode(type); return(ValueOnStack.MakeVBox(typeCode)); }