Thank you for letting me muck around with the code. To me it looks like the answer should look something like the code below.
From what I have read online the com_interface attribute was originally made to get GCC to make vtables compatible with COM objects. (With my compiler ("gcc (GCC) 3.4.2 (mingw-special)") com_interface is the default.) All that would be needed is replacing com_interface with the correct class attribute, if it exists. (That's why I said the answer should look something like the code below. The mechanism is there, but not necessarily the attribute you need, although my guess is the attribute already exists.)
EDIT:
I'm rambling a bit right now because I have dialup (the bad kind) and it will take me some time to get wxDev-C++, the YRPP source, and a svn client and don't want to forget to check this out. Sorry about that.
From what I have read online the com_interface attribute was originally made to get GCC to make vtables compatible with COM objects. (With my compiler ("gcc (GCC) 3.4.2 (mingw-special)") com_interface is the default.) All that would be needed is replacing com_interface with the correct class attribute, if it exists. (That's why I said the answer should look something like the code below. The mechanism is there, but not necessarily the attribute you need, although my guess is the attribute already exists.)
Code:
#if defined(__GNUC__)
# define VC_VTABLE __attribute__((com_interface))
#else
# define VC_VTABLE
#endif
class InfantryClass {
public:
int SelectWeapon(TechnoClass *target);
virtual void Update();
} VC_VTABLE;
I'm rambling a bit right now because I have dialup (the bad kind) and it will take me some time to get wxDev-C++, the YRPP source, and a svn client and don't want to forget to check this out. Sorry about that.