bool Emulate_Beq() { var val2 = instructionEmulator.Pop(); var val1 = instructionEmulator.Pop(); if (val1.IsInt32() && val2.IsInt32()) { return(EmulateBranch(2, Int32Value.CompareEq((Int32Value)val1, (Int32Value)val2))); } else if (val1.IsInt64() && val2.IsInt64()) { return(EmulateBranch(2, Int64Value.CompareEq((Int64Value)val1, (Int64Value)val2))); } else if (val1.IsReal8() && val2.IsReal8()) { return(EmulateBranch(2, Real8Value.CompareEq((Real8Value)val1, (Real8Value)val2))); } else if (val1.IsNull() && val2.IsNull()) { return(EmulateBranch(2, true)); } else { return(false); } }