I want to use the Code Analysis in Visual Studio 2017 but I'm using Qt and it gives me a lot of warnings from the headers. I've tried turning off warnings:
#pragma warning(push, 0)
#include <QtGlobal>
#pragma warning(pop)
but it doesn't help. I also tried using this:
#include <codeanalysiswarnings.h>
#pragma warning(push, 0)
#pragma warning(disable : ALL_CODE_ANALYSIS_WARNINGS)
#include <QtGlobal>
#pragma warning(pop)
but no help. How can I disable the Code Analysis for the Qt external headers?
See Question&Answers more detail:os