Skip to content

Latest commit

 

History

History
33 lines (25 loc) · 894 Bytes

compiler-warning-level-3-c4159.md

File metadata and controls

33 lines (25 loc) · 894 Bytes
description title ms.date f1_keywords helpviewer_keywords ms.assetid
Learn more about: Compiler Warning (level 3) C4159
Compiler Warning (level 3) C4159
11/04/2016
C4159
C4159
e2cf964e-f4b8-4b2c-9569-1abb94307232

Compiler Warning (level 3) C4159

#pragma pragma(pop,...) : has popped previously pushed identifier 'identifier'

Remarks

Your source code contains a push instruction with an identifier for a pragma followed by a pop instruction without an identifier. As a result, identifier is popped, and subsequent uses of identifier may cause unexpected behavior.

Example

To avoid this warning, give an identifier in the pop instruction. For example:

// C4159.cpp
// compile with: /W3
#pragma pack(push, f)
#pragma pack(pop)   // C4159

// using the identifier resolves the warning
// #pragma pack(pop, f)

int main()
{
}