Compiler Error C3291
Collapse the table of content
Expand the table of content
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here. ArchiveDisclaimer

Compiler Error C3291

'default' : cannot be the name of a trivial property

A trivial property cannot be named default. See property for more information.

The following sample generates C3291.

// C3291.cpp
// compile with: /clr /c
ref struct C {
   property System::String ^ default;   // C3291
   property System::String ^ Default;   // OK
© 2015 Microsoft