public static object TrueDivide(long x, object other)
 {
     if (other is int)
     {
         return(TrueDivide(x, (int)other));
     }
     if (other is BigInteger)
     {
         return(TrueDivide(x, (BigInteger)other));
     }
     if (other is long)
     {
         return(TrueDivide(x, (long)other));
     }
     if (other is double)
     {
         return(TrueDivide(x, (double)other));
     }
     if (other is Complex64)
     {
         return(ComplexOps.TrueDivide(x, (Complex64)other));
     }
     if (other is bool)
     {
         return(TrueDivide(x, (bool)other ? 1 : 0));
     }
     if (other is float)
     {
         return(TrueDivide(x, (float)other));
     }
     if (other is ExtensibleInt)
     {
         return(TrueDivide(x, ((ExtensibleInt)other).value));
     }
     if (other is ExtensibleFloat)
     {
         return(TrueDivide(x, ((ExtensibleFloat)other).value));
     }
     if (other is ExtensibleComplex)
     {
         return(TrueDivide(x, ((ExtensibleComplex)other).value));
     }
     if (other is byte)
     {
         return(TrueDivide(x, (int)((byte)other)));
     }
     return(Ops.NotImplemented);
 }
Beispiel #2
0
 private static object TrueDivide(int x, Complex64 y)
 {
     return(ComplexOps.TrueDivide(Complex64.MakeReal(x), y));
 }