Skip to content

Latest commit

 

History

History
29 lines (23 loc) · 880 Bytes

compiler-warning-c4693.md

File metadata and controls

29 lines (23 loc) · 880 Bytes
description title ms.date f1_keywords helpviewer_keywords ms.assetid
Learn more about: Compiler Warning C4693
Compiler Warning C4693
10/25/2017
C4693
C4693
72d8db01-5e6f-4794-8731-76107e8f064a

Compiler Warning C4693

'class': a sealed abstract class cannot have any instance members 'Test'

If a type is marked sealed and abstract, it can only have static members.

This warning is automatically promoted to an error. If you wish to modify this behavior, use #pragma warning.

Example

The following sample generates C4693.

// C4693.cpp
// compile with: /clr /c
public ref class Public_Ref_Class sealed abstract {
public:
   void Test() {}   // C4693
   static void Test2() {}   // OK
};