If you have a header that has a
#pragma warning(push)
on top and a
#pragma warning(pop)
at the bottom, then after the header is parsed, the warning settings are reset. You'll need to put a pragma
in your cpp file as well.
#include "someheader.h"
//this is the implementation file
//some code
translates, basically, to:
//contents of the header file
#pragma warning(push)
#pragma warning(disable:4251)
//warning is disabled here
#pragma warning(pop)
//popped - initial state (warning enabled) back
//this is the implementation file
//some code