private MathOpcode CreateMathOpcode(MathOperator op) { MathOpcode opcode = null; switch (op) { case MathOperator.None: return(opcode); case MathOperator.Plus: return(new PlusOpcode()); case MathOperator.Minus: return(new MinusOpcode()); case MathOperator.Div: return(new DivideOpcode()); case MathOperator.Multiply: return(new MultiplyOpcode()); case MathOperator.Mod: return(new ModulusOpcode()); case MathOperator.Negate: return(new NegateOpcode()); } return(opcode); }
MathOpcode CreateMathOpcode(MathOperator op) { MathOpcode opcode = null; switch (op) { case MathOperator.None: Fx.Assert(""); break; case MathOperator.Plus: opcode = new PlusOpcode(); break; case MathOperator.Minus: opcode = new MinusOpcode(); break; case MathOperator.Div: opcode = new DivideOpcode(); break; case MathOperator.Multiply: opcode = new MultiplyOpcode(); break; case MathOperator.Mod: opcode = new ModulusOpcode(); break; case MathOperator.Negate: opcode = new NegateOpcode(); break; } return(opcode); }