Could I find some translator which could translate partial C++ codes
to equivalent C codes? like
int max(int A, int B);
double max(double B, double B);
would be translate to something like
int maxInt(int A, int B);
double maxDouble(double B, double B);
template<typename T = int, double, char>
T max(T A, T B);
would be translate to something like
int maxInt(int A, int B);
double maxDouble(double B, double B);
char maxChar(char B, char B);
Or I should write one for myself?
Ok, I know that I should use C++ if I like it
but I can't choose it by my free will
I have to design something like qsort if I have to use C
and it is what I am refuse to.That kind of codes are not
efficient at all but hard to debug and maintain.
But it is even harder to maintain if I don't design a
"partial generic" function by the way like that.