object
complex
Type Members
-
-
Value Members
-
final
def
!=(arg0: Any): Boolean
-
final
def
##(): Int
-
final
def
==(arg0: Any): Boolean
-
final
def
asInstanceOf[T0]: T0
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
def
clone(): AnyRef
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
final
def
eq(arg0: AnyRef): Boolean
-
def
equals(arg0: Any): Boolean
-
def
finalize(): Unit
-
final
def
getClass(): Class[_]
-
def
hashCode(): Int
-
final
def
isInstanceOf[T0]: Boolean
-
final
def
ne(arg0: AnyRef): Boolean
-
final
def
notify(): Unit
-
final
def
notifyAll(): Unit
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
-
def
toString(): String
-
final
def
wait(): Unit
-
final
def
wait(arg0: Long, arg1: Int): Unit
-
final
def
wait(arg0: Long): Unit
All functions take complex but Scala Native does not support pass by value so we pass a pointer to an Array of length 2 and have a small wrapper in C doing the conversion to call the native function. Currently Scala Native and JVM have no direct support for long double so these methods are not implemented.
Since the user must manage the memory, we pass a buffer passed to each function for storing the result and is also is returned from the function so functions can be chained together. This adds one additional parameter to the function compared to the C API.
Implicit classes are provided for convenience.
References: https://en.wikipedia.org/wiki/C_data_types C99 also added complex types: float _Complex, double _Complex, long double _Complex https://en.wikipedia.org/wiki/Long_double http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/complex.h.html