Skip to content

Latest commit

 

History

History
32 lines (26 loc) · 775 Bytes

compiler-warning-level-1-c4384.md

File metadata and controls

32 lines (26 loc) · 775 Bytes
description title ms.date f1_keywords helpviewer_keywords
Learn more about: Compiler Warning (level 1) C4384
Compiler Warning (level 1) C4384
11/04/2016
C4384
C4384

Compiler Warning (level 1) C4384

#pragma 'pragma_name' should only be used at global scope

A pragma directive that must be applied at a global scope, was found in a different scope.

The warning applies to the following pragma directives:

Example

The following sample generates C4384.

// C4384.cpp
// compile with: /c /W1
namespace n {
   #pragma make_public(N::C)   // C4384
   namespace N {
      class C {};
   }
}