共用方式為


編譯器錯誤 C3652

'override' :明確覆寫的函式必須是虛擬

執行明確覆寫的函式必須是虛擬的。 如需詳細資訊,請參閱 明確覆寫

下列範例會產生 C3652:

// C3652.cpp
// compile with: /clr /c
public interface class I {
   void f();
};

public ref struct R : I {
   void f() = I::f {}   // C3652
   // try the following line instead
   // virtual void f() = I::f {}
};