这是我的 C++ CLI 代码:
public ref class SVeh{
public:
    bool Is( Pla^ For);
};
Pla是在 之后定义的SVeh。
public ref class Pla{
public:
    bool somemethod();
};
编译器将类Pla作为未知标识符并且不编译它。如何解决这个问题?
这是我的 C++ CLI 代码:
public ref class SVeh{
public:
    bool Is( Pla^ For);
};
Pla是在 之后定义的SVeh。
public ref class Pla{
public:
    bool somemethod();
};
编译器将类Pla作为未知标识符并且不编译它。如何解决这个问题?
我不知道 C++/CLI,但如果它类似于 C++,你可以前向声明 Pla:
ref class Pla;
public ref class SVeh{
  // rest of code
有关更多信息,请参阅此问题。