Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Expand Minimize
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.

Compiler Warning (level 1) C4377

Error Message

native types are private by default; -d1PrivateNativeTypes is deprecated

In previous releases, native types in assemblies were public by default, and an internal, undocumented compiler option (/d1PrivateNativeTypes) was used to make them private.

All types, native and CLR, are now private by default in an assembly, so /d1PrivateNativeTypes is no longer needed.

Example

The following sample generates C4377.

// C4377.cpp
// compile with: /clr /d1PrivateNativeTypes /W1
// C4377 warning expected
int main() {}

Community Additions

ADD
Show:
© 2015 Microsoft