编译器警告(等级 3)C4280

“operator ->”是通过类型“type”自递归的

你的代码错误地允许 operator-> 调用自身

以下示例生成 C4280:

// C4280.cpp
// compile with: /W3 /WX
struct A
{
   int z;
   A& operator ->();
};

void f(A y)
{
   int i = y->z; // C4280
}