Skip to content

Latest commit

 

History

History
30 lines (25 loc) · 580 Bytes

compiler-error-c3277.md

File metadata and controls

30 lines (25 loc) · 580 Bytes
description title ms.date f1_keywords helpviewer_keywords ms.assetid
Learn more about: Compiler Error C3277
Compiler Error C3277
11/04/2016
C3277
C3277
8ac5f476-e30c-4879-92c6-f03cdbd74045

Compiler Error C3277

cannot define an unmanaged enum 'enum' inside managed 'type'

An enumeration was defined incorrectly inside a managed type.

The following sample generates C3277:

// C3277a.cpp
// compile with: /clr
ref class A
{
   enum E {e1,e2};   // C3277
   // try the following line instead
   // enum class E {e1,e2};
};

int main()
{
}