M
ma740988
Given:
void mxvmvd(double *pv1, long ninc1, double *pso, long n);
void mxvmvf( float *pv1, long ninc1, float *pso, long n);
How would I write a generic solution (template version) that'll call
the appropriate function based on the float or double type?
I've got vendor API's that has two separate functions that differ only
by 'f' (float) or 'd' (double). My intent is to put a wrappers around
these functions. I tempted to do a typeid 'check' but I'm unsure if
that's necessary/is the right approach.
Thanks in advance.
void mxvmvd(double *pv1, long ninc1, double *pso, long n);
void mxvmvf( float *pv1, long ninc1, float *pso, long n);
How would I write a generic solution (template version) that'll call
the appropriate function based on the float or double type?
I've got vendor API's that has two separate functions that differ only
by 'f' (float) or 'd' (double). My intent is to put a wrappers around
these functions. I tempted to do a typeid 'check' but I'm unsure if
that's necessary/is the right approach.
Thanks in advance.