virtualvoid__attribute__((thiscall))f();// expected-note{{overridden virtual function is here}}
};
classB:publicA{
public:
void__attribute__((cdecl))f();// expected-error{{virtual function 'f' has different calling convention attributes ('void () __attribute__((cdecl))') than the function it overrides (which has calling convention 'void () __attribute__((thiscall))'}}
};
classC:publicA{
public:
void__attribute__((thiscall))f();// This override is correct
};
classD:publicA{
public:
voidf();// This override is correct because thiscall is the default calling convention for class members
};
classE{
public:
virtualvoid__attribute__((stdcall))g();// expected-note{{overridden virtual function is here}}
voidg();// expected-error{{virtual function 'g' has different calling convention attributes ('void () __attribute__((thiscall))') than the function it overrides (which has calling convention 'void () __attribute__((stdcall))'}}