Given this code
#include <cassert>
class ChangeSignature
{
public:
int Method3(int a, int b);
};
int ChangeSignature::Method3(int a, int b)
{
return a + b;
}
static void TestMethods
{
ChangeSignature c;
int (ChangeSignature::*result)(int, int) = &ChangeSignature::Method3;
int const sum =
}
Type (c.* right after the = on the last line and VAX inserts bogus code:
int const sum = (c.Method3*
I verified this came from VAX by disabling VAX and typing the code and then I get exactly what I typed. VAX should never insert incorrect code when I am typing correct code. The correct code is:
int const sum = (c.*result)(3, 4);