M
mark
I've got a C library that I want to access from C++. I'd like to pass
complex number portably between them. Right now, I've got code in the
header file to define the argument according to C or C++.
#ifdef __cplusplus
# include <complex>
typedef std::complex<float> float_complex;
#else
# include <complex.h>
typedef float complex float_complex;
#endif
How portable is this?
complex number portably between them. Right now, I've got code in the
header file to define the argument according to C or C++.
#ifdef __cplusplus
# include <complex>
typedef std::complex<float> float_complex;
#else
# include <complex.h>
typedef float complex float_complex;
#endif
How portable is this?