Earlier was asking about writing a c wrapper for c++ classes ( C Wrapper for C++ ), which is basically clear.
There’s one more question though: how do I deal with c++ templates?
Let’s say this is my class:
template<typename T> class Temp
{
T get();
void set(T t);
}
Is there an elegant way to write a c wrapper?
You have to write a separate wrapper for each specialization.