编译器错误 C3400

涉及“constraint_1”和“constraint_2”的循环约束依赖项

编译器检测到循环约束。

有关详细信息,请参阅泛型类型参数的约束 (C++/CLI)

示例

以下示例生成 C3400。

// C3400.cpp
// compile with: /clr /c
generic<class T, class U>
where T : U
where U : T   // C3400
public ref struct R {};