From c9cdd2cd8d9039b28e0f056855dd84ba0da597a3 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Sat, 6 Aug 2016 21:42:40 +0300 Subject: [PATCH] Using macros QT_WARNING_DISABLE_*. --HG-- branch : develop --- src/app/tape/mapplication.cpp | 17 +++------ src/app/tape/tmainwindow.cpp | 16 +++------ src/app/valentina/core/vapplication.cpp | 16 +++------ src/app/valentina/dialogs/dialoghistory.cpp | 11 +++--- src/app/valentina/mainwindow.cpp | 36 ++++++------------- src/app/valentina/mainwindowsnogui.cpp | 10 ++---- src/app/valentina/xml/vpattern.cpp | 10 ++---- src/libs/ifc/xml/vdomdocument.h | 11 +++--- src/libs/qmuparser/qmudef.h | 10 ++---- src/libs/qmuparser/qmuparserbase.cpp | 20 ++++------- src/libs/qmuparser/qmuparserbytecode.h | 11 +++--- src/libs/qmuparser/qmuparsertest.cpp | 10 ++---- src/libs/vdxf/dxflib/dl_codes.h | 5 ++- src/libs/vdxf/dxflib/dl_entities.h | 12 +++---- src/libs/vdxf/vdxfengine.cpp | 26 ++++---------- src/libs/vgeometry/vabstractarc_p.h | 9 ++--- src/libs/vgeometry/vabstractcurve_p.h | 11 +++--- src/libs/vgeometry/varc_p.h | 11 +++--- src/libs/vgeometry/vcubicbezier_p.h | 11 +++--- src/libs/vgeometry/vcubicbezierpath_p.h | 11 +++--- src/libs/vgeometry/vellipticalarc_p.h | 11 +++--- src/libs/vgeometry/vgobject_p.h | 11 +++--- src/libs/vgeometry/vpointf.h | 12 +++---- src/libs/vgeometry/vpointf_p.h | 11 +++--- src/libs/vgeometry/vspline_p.h | 10 ++---- src/libs/vgeometry/vsplinepath_p.h | 10 ++---- src/libs/vgeometry/vsplinepoint_p.h | 10 ++---- src/libs/vlayout/vabstractdetail_p.h | 12 +++---- src/libs/vlayout/vbank.cpp | 16 +++------ src/libs/vlayout/vcontour_p.h | 12 +++---- src/libs/vlayout/vlayoutdetail_p.h | 11 ++---- src/libs/vlayout/vlayoutpaper_p.h | 10 ++---- .../vmisc/backport/qcommandlineoption.cpp | 12 +++---- src/libs/vmisc/backport/qcommandlineoption.h | 12 +++---- .../vmisc/backport/qcommandlineparser.cpp | 17 ++++----- src/libs/vmisc/backport/qcommandlineparser.h | 12 +++---- src/libs/vmisc/qxtcsvmodel.cpp | 12 +++---- src/libs/vmisc/vlockguard.h | 12 +++---- src/libs/vobj/delaunay.cpp | 13 +++---- src/libs/vobj/vobjengine.cpp | 17 ++++----- src/libs/vpatterndb/variables/varcradius_p.h | 12 +++---- .../vpatterndb/variables/vcurvevariable_p.h | 11 +++--- src/libs/vpatterndb/variables/vincrement_p.h | 11 +++--- .../variables/vinternalvariable_p.h | 11 +++--- src/libs/vpatterndb/variables/vlineangle_p.h | 11 +++--- src/libs/vpatterndb/variables/vlinelength_p.h | 11 +++--- .../vpatterndb/variables/vmeasurement_p.h | 11 +++--- src/libs/vpatterndb/variables/vvariable_p.h | 12 +++---- src/libs/vpatterndb/vcontainer.cpp | 16 +++------ src/libs/vpatterndb/vcontainer.h | 17 +++------ src/libs/vpatterndb/vdetail_p.h | 11 +++--- src/libs/vpatterndb/vnodedetail_p.h | 11 +++--- .../vabstractpropertyfactory.h | 11 +++--- .../vpropertyexplorer/vpropertyformview_p.h | 11 +++--- .../vpropertyexplorer/vpropertyformwidget_p.h | 11 +++--- .../vpropertyexplorer/vwidgetproperty_p.h | 11 +++--- .../drawTools/operation/vtoolrotation.cpp | 30 +++++----------- .../toollinepoint/vtoolcurveintersectaxis.cpp | 10 ++---- .../toolsinglepoint/vtoolsinglepoint.cpp | 16 +++------ src/libs/vtools/tools/vtooluniondetails.cpp | 16 +++------ .../visualization/line/vistoolrotation.cpp | 10 ++---- 61 files changed, 266 insertions(+), 522 deletions(-) diff --git a/src/app/tape/mapplication.cpp b/src/app/tape/mapplication.cpp index 897668a0f..d134681da 100644 --- a/src/app/tape/mapplication.cpp +++ b/src/app/tape/mapplication.cpp @@ -36,6 +36,7 @@ #include "../ifc/exception/vexceptionwrongid.h" #include "../vmisc/logging.h" #include "../vmisc/vsysexits.h" +#include "../vmisc/diagnostic.h" #include "../qmuparser/qmuparsererror.h" #include @@ -51,21 +52,13 @@ #include #include -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(mApp, "m.application") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP #if QT_VERSION < QT_VERSION_CHECK(5, 2, 0) # include "../vmisc/backport/qcommandlineparser.h" diff --git a/src/app/tape/tmainwindow.cpp b/src/app/tape/tmainwindow.cpp index 397ada752..68438e6c7 100644 --- a/src/app/tape/tmainwindow.cpp +++ b/src/app/tape/tmainwindow.cpp @@ -62,21 +62,13 @@ #define DIALOG_MAX_FORMULA_HEIGHT 64 -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(tMainWindow, "t.mainwindow") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP // We need this enum in case we will add or delete a column. And also make code more readable. enum {ColumnName = 0, ColumnFullName, ColumnCalcValue, ColumnFormula, ColumnBaseValue, ColumnInSizes, ColumnInHeights}; diff --git a/src/app/valentina/core/vapplication.cpp b/src/app/valentina/core/vapplication.cpp index c5b5bc638..d5eb0ee38 100644 --- a/src/app/valentina/core/vapplication.cpp +++ b/src/app/valentina/core/vapplication.cpp @@ -53,21 +53,13 @@ #include #include -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(vApp, "v.application") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP Q_DECL_CONSTEXPR auto DAYS_TO_KEEP_LOGS = 3; diff --git a/src/app/valentina/dialogs/dialoghistory.cpp b/src/app/valentina/dialogs/dialoghistory.cpp index 097235731..64a069de1 100644 --- a/src/app/valentina/dialogs/dialoghistory.cpp +++ b/src/app/valentina/dialogs/dialoghistory.cpp @@ -38,6 +38,7 @@ #include "../vtools/tools/drawTools/toolpoint/toolsinglepoint/toolcut/vtoolcutsplinepath.h" #include "../vtools/tools/drawTools/toolpoint/toolsinglepoint/toolcut/vtoolcutarc.h" #include "../xml/vpattern.h" +#include "../vmisc/diagnostic.h" //--------------------------------------------------------------------------------------------------------------------- /** @@ -196,10 +197,8 @@ void DialogHistory::FillTable() } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") /** * @brief Record return description for record * @param tool record data @@ -400,9 +399,7 @@ QString DialogHistory::Record(const VToolRecord &tool) return tr("Can't create record."); } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- /** diff --git a/src/app/valentina/mainwindow.cpp b/src/app/valentina/mainwindow.cpp index c47d84ded..391848767 100644 --- a/src/app/valentina/mainwindow.cpp +++ b/src/app/valentina/mainwindow.cpp @@ -83,21 +83,13 @@ #include #endif //defined(Q_OS_MAC) -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(vMainWindow, "v.mainwindow") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP const QString autosavePrefix = QStringLiteral(".autosave"); @@ -1730,10 +1722,8 @@ void MainWindow::MouseMove(const QPointF &scenePos) } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") /** * @brief CancelTool cancel tool. */ @@ -1889,9 +1879,7 @@ void MainWindow::CancelTool() redoAction->setEnabled(qApp->getUndoStack()->canRedo()); } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- /** @@ -3235,10 +3223,8 @@ void MainWindow::CreateMenus() } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") void MainWindow::LastUsedTool() { // This check helps to find missed tools in the switch @@ -3411,9 +3397,7 @@ void MainWindow::LastUsedTool() } } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- void MainWindow::AddDocks() diff --git a/src/app/valentina/mainwindowsnogui.cpp b/src/app/valentina/mainwindowsnogui.cpp index d481ac942..c0c349355 100644 --- a/src/app/valentina/mainwindowsnogui.cpp +++ b/src/app/valentina/mainwindowsnogui.cpp @@ -757,10 +757,8 @@ void MainWindowsNoGUI::ObjFile(const QString &name, int i) const } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") void MainWindowsNoGUI::DxfFile(const QString &name, int i) const { @@ -796,9 +794,7 @@ void MainWindowsNoGUI::DxfFile(const QString &name, int i) const } } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- void MainWindowsNoGUI::PreparePaper(int index) const diff --git a/src/app/valentina/xml/vpattern.cpp b/src/app/valentina/xml/vpattern.cpp index 6ddceb81c..fcf070350 100644 --- a/src/app/valentina/xml/vpattern.cpp +++ b/src/app/valentina/xml/vpattern.cpp @@ -3295,10 +3295,8 @@ void VPattern::ToolsCommonAttributes(const QDomElement &domElement, quint32 &id) } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") QRectF VPattern::ActiveDrawBoundingRect() const { @@ -3430,9 +3428,7 @@ QRectF VPattern::ActiveDrawBoundingRect() const return rec; } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- template diff --git a/src/libs/ifc/xml/vdomdocument.h b/src/libs/ifc/xml/vdomdocument.h index 6c51cacee..73dc83660 100644 --- a/src/libs/ifc/xml/vdomdocument.h +++ b/src/libs/ifc/xml/vdomdocument.h @@ -36,13 +36,12 @@ #include "../ifc/ifcdef.h" #include "../vmisc/def.h" #include "../vmisc/logging.h" +#include "../vmisc/diagnostic.h" Q_DECLARE_LOGGING_CATEGORY(vXML) -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") /** * @brief The VDomDocument class represents a Valentina document (.val file). @@ -166,8 +165,6 @@ inline void VDomDocument::SetAttribute(QDomElement &domElement QStringLiteral("individual")); } -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VDOMDOCUMENT_H diff --git a/src/libs/qmuparser/qmudef.h b/src/libs/qmuparser/qmudef.h index 9f59b4e6c..dfddbb97f 100644 --- a/src/libs/qmuparser/qmudef.h +++ b/src/libs/qmuparser/qmudef.h @@ -84,10 +84,8 @@ #endif // QT_VERSION < QT_VERSION_CHECK(5, 5, 0) -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wattributes" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wattributes") #ifdef Q_CC_MSVC #include @@ -99,9 +97,7 @@ inline QString NameRegExp() return QStringLiteral("^([^0-9*/^+\\-=\\s()?%:;!.,`'\"]){1,1}([^*/^+\\-=\\s()?%:;!.,`'\"]){0,}$"); } -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP static inline bool QmuFuzzyComparePossibleNulls(double p1, double p2) Q_REQUIRED_RESULT; static inline bool QmuFuzzyComparePossibleNulls(double p1, double p2) diff --git a/src/libs/qmuparser/qmuparserbase.cpp b/src/libs/qmuparser/qmuparserbase.cpp index e3b356a4b..0c1e28ece 100644 --- a/src/libs/qmuparser/qmuparserbase.cpp +++ b/src/libs/qmuparser/qmuparserbase.cpp @@ -1026,25 +1026,17 @@ qreal QmuParserBase::ParseCmdCodeBulk(int nOffset, int nThreadID) const continue; case cmLAND: --sidx; -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wfloat-equal" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wfloat-equal") Stack[sidx] = static_cast(Stack[sidx]) && static_cast(Stack[sidx+1]); -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP continue; case cmLOR: --sidx; -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wfloat-equal" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wfloat-equal") Stack[sidx] = static_cast(Stack[sidx]) || static_cast(Stack[sidx+1]); -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP continue; case cmASSIGN: // Bugfix for Bulkmode: diff --git a/src/libs/qmuparser/qmuparserbytecode.h b/src/libs/qmuparser/qmuparserbytecode.h index a466fa068..bbbf352ce 100644 --- a/src/libs/qmuparser/qmuparserbytecode.h +++ b/src/libs/qmuparser/qmuparserbytecode.h @@ -24,16 +24,15 @@ #include "qmuparserdef.h" #include "qmuparsertoken.h" +#include "qmudef.h" /** * @file * @brief Definition of the parser bytecode class. */ -#ifdef Q_CC_CLANG -#pragma clang diagnostic push -#pragma clang diagnostic ignored "-Wnested-anon-types" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wnested-anon-types") namespace qmu { struct SToken @@ -69,9 +68,7 @@ struct SToken }; }; -#ifdef Q_CC_CLANG -#pragma clang diagnostic pop -#endif +QT_WARNING_POP /** * @brief Bytecode implementation of the Math Parser. diff --git a/src/libs/qmuparser/qmuparsertest.cpp b/src/libs/qmuparser/qmuparsertest.cpp index e1ff4869c..010275b3a 100644 --- a/src/libs/qmuparser/qmuparsertest.cpp +++ b/src/libs/qmuparser/qmuparsertest.cpp @@ -1392,14 +1392,10 @@ int QmuParserTester::EqnTest ( const QString &a_str, double a_fRes, bool a_fPass // The tests equations never result in infinity, if they do thats a bug. // reference: // http://sourceforge.net/projects/muparser/forums/forum/462843/topic/5037825 -#if defined(Q_CC_MSVC) -#pragma warning(push) -#pragma warning(disable:4127) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_MSVC(4127) if (std::numeric_limits::has_infinity) -#if defined(Q_CC_MSVC) -#pragma warning(pop) -#endif +QT_WARNING_POP { bCloseEnough &= (not QmuFuzzyComparePossibleNulls( fabs ( fVal[i] ), std::numeric_limits::infinity()) ); diff --git a/src/libs/vdxf/dxflib/dl_codes.h b/src/libs/vdxf/dxflib/dl_codes.h index c3b16d6a9..321d1d34a 100644 --- a/src/libs/vdxf/dxflib/dl_codes.h +++ b/src/libs/vdxf/dxflib/dl_codes.h @@ -31,6 +31,7 @@ #define DXF_CODES_H #include "dl_global.h" +#include "../vmisc/diagnostic.h" #if defined(Q_CC_MSVC) #if (_MSC_VER > 1000) @@ -50,9 +51,7 @@ #ifdef _WIN32 #undef M_PI #define M_PI 3.14159265358979323846 -#if defined(Q_CC_MSVC) -#pragma warning(disable : 4800) -#endif // Q_CC_MSVC +QT_WARNING_DISABLE_MSVC(4800) #endif #ifndef M_PI diff --git a/src/libs/vdxf/dxflib/dl_entities.h b/src/libs/vdxf/dxflib/dl_entities.h index a6507818e..b6d8e07c0 100644 --- a/src/libs/vdxf/dxflib/dl_entities.h +++ b/src/libs/vdxf/dxflib/dl_entities.h @@ -27,6 +27,7 @@ #include "dl_global.h" #include "../dxfdef.h" +#include "../vmisc/diagnostic.h" #include #include @@ -809,11 +810,8 @@ struct DXFLIB_EXPORT DL_MTextData double angle; }; - -#ifdef Q_CC_CLANG - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wweak-vtables" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wweak-vtables") /** * Text Data. @@ -945,9 +943,7 @@ struct DXFLIB_EXPORT DL_AttributeData : public DL_TextData std::string tag; }; -#ifdef Q_CC_CLANG - #pragma clang diagnostic pop -#endif +QT_WARNING_POP /** * Generic Dimension Data. diff --git a/src/libs/vdxf/vdxfengine.cpp b/src/libs/vdxf/vdxfengine.cpp index 91429ecaf..1c9f7d201 100644 --- a/src/libs/vdxf/vdxfengine.cpp +++ b/src/libs/vdxf/vdxfengine.cpp @@ -39,13 +39,9 @@ //--------------------------------------------------------------------------------------------------------------------- static inline QPaintEngine::PaintEngineFeatures svgEngineFeatures() { -#if defined(Q_CC_CLANG) -#pragma clang diagnostic push -#pragma clang diagnostic ignored "-Wsign-conversion" -#elif defined (Q_CC_INTEL) -#pragma warning( push ) -#pragma warning( disable: 68 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wsign-conversion") +QT_WARNING_DISABLE_INTEL(68) return QPaintEngine::PaintEngineFeatures( QPaintEngine::AllFeatures @@ -54,11 +50,7 @@ static inline QPaintEngine::PaintEngineFeatures svgEngineFeatures() & ~QPaintEngine::ConicalGradientFill & ~QPaintEngine::PorterDuff); -#if defined(Q_CC_CLANG) -#pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) -#pragma warning( pop ) -#endif +QT_WARNING_POP } //--------------------------------------------------------------------------------------------------------------------- @@ -566,10 +558,8 @@ void VDxfEngine::setInsunits(const VarInsunits &var) } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") double VDxfEngine::FromPixel(double pix, const VarInsunits &unit) const { @@ -585,6 +575,4 @@ double VDxfEngine::FromPixel(double pix, const VarInsunits &unit) const return 0; } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP diff --git a/src/libs/vgeometry/vabstractarc_p.h b/src/libs/vgeometry/vabstractarc_p.h index 8f1444312..98ff70226 100644 --- a/src/libs/vgeometry/vabstractarc_p.h +++ b/src/libs/vgeometry/vabstractarc_p.h @@ -32,12 +32,11 @@ #include #include "vgeometrydef.h" #include "../vmisc/vabstractapplication.h" +#include "../vmisc/diagnostic.h" #include "vpointf.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VAbstractArcData : public QSharedData { @@ -145,4 +144,6 @@ VAbstractArcData::VAbstractArcData(const VAbstractArcData &arc) VAbstractArcData::~VAbstractArcData() {} +QT_WARNING_POP + #endif // VABSTRACTARCDATA_H diff --git a/src/libs/vgeometry/vabstractcurve_p.h b/src/libs/vgeometry/vabstractcurve_p.h index 3d5920bb5..29338ef7e 100644 --- a/src/libs/vgeometry/vabstractcurve_p.h +++ b/src/libs/vgeometry/vabstractcurve_p.h @@ -32,11 +32,10 @@ #include #include "../ifc/ifcdef.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VAbstractCurveData : public QSharedData { @@ -64,8 +63,6 @@ private: VAbstractCurveData::~VAbstractCurveData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VABSTRACTCURVE_P_H diff --git a/src/libs/vgeometry/varc_p.h b/src/libs/vgeometry/varc_p.h index 99cb4f2c0..b76dd3e0d 100644 --- a/src/libs/vgeometry/varc_p.h +++ b/src/libs/vgeometry/varc_p.h @@ -32,11 +32,10 @@ #include #include "vgeometrydef.h" #include "../vmisc/vabstractapplication.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VArcData : public QSharedData { @@ -86,8 +85,6 @@ VArcData::VArcData(const VArcData &arc) VArcData::~VArcData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VARC_P_H diff --git a/src/libs/vgeometry/vcubicbezier_p.h b/src/libs/vgeometry/vcubicbezier_p.h index 168d2d127..f94c6931f 100644 --- a/src/libs/vgeometry/vcubicbezier_p.h +++ b/src/libs/vgeometry/vcubicbezier_p.h @@ -35,11 +35,10 @@ #include "vpointf.h" #include "../vmisc/vabstractapplication.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VCubicBezierData : public QSharedData { @@ -98,8 +97,6 @@ VCubicBezierData::~VCubicBezierData() { } -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VCUBICBEZIER_P_H diff --git a/src/libs/vgeometry/vcubicbezierpath_p.h b/src/libs/vgeometry/vcubicbezierpath_p.h index 34fd9b6f0..2a3f46952 100644 --- a/src/libs/vgeometry/vcubicbezierpath_p.h +++ b/src/libs/vgeometry/vcubicbezierpath_p.h @@ -32,11 +32,10 @@ #include #include "vpointf.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VCubicBezierPathData : public QSharedData { @@ -63,8 +62,6 @@ private: VCubicBezierPathData::~VCubicBezierPathData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VCUBICBEZIERPATH_P_H diff --git a/src/libs/vgeometry/vellipticalarc_p.h b/src/libs/vgeometry/vellipticalarc_p.h index aa3c04194..ed8ec938e 100644 --- a/src/libs/vgeometry/vellipticalarc_p.h +++ b/src/libs/vgeometry/vellipticalarc_p.h @@ -3,12 +3,11 @@ #include #include "../vmisc/vabstractapplication.h" +#include "../vmisc/diagnostic.h" #include "vpointf.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VEllipticalArcData : public QSharedData { @@ -78,9 +77,7 @@ VEllipticalArcData::VEllipticalArcData(const VEllipticalArcData &arc) VEllipticalArcData::~VEllipticalArcData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VELLIPTICALARC_P diff --git a/src/libs/vgeometry/vgobject_p.h b/src/libs/vgeometry/vgobject_p.h index fb94828c0..6a059b4bb 100644 --- a/src/libs/vgeometry/vgobject_p.h +++ b/src/libs/vgeometry/vgobject_p.h @@ -32,11 +32,10 @@ #include #include "vgeometrydef.h" #include "../ifc/ifcdef.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VGObjectData : public QSharedData { @@ -77,8 +76,6 @@ private: VGObjectData::~VGObjectData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VGOBJECT_P_H diff --git a/src/libs/vgeometry/vpointf.h b/src/libs/vgeometry/vpointf.h index 904af4b05..e947b482b 100644 --- a/src/libs/vgeometry/vpointf.h +++ b/src/libs/vgeometry/vpointf.h @@ -33,14 +33,14 @@ #include +#include "../vmisc/diagnostic.h" + class QPointF; class QString; class VPointFData; -#if defined (Q_CC_INTEL) -#pragma warning(push) -#pragma warning(disable : 2304) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_INTEL(2304) /** * @brief The VPointF class keep data of point. @@ -78,8 +78,6 @@ private: Q_DECLARE_METATYPE(VPointF) Q_DECLARE_TYPEINFO(VPointF, Q_MOVABLE_TYPE); -#if defined(Q_CC_INTEL) -#pragma warning(pop) -#endif +QT_WARNING_POP #endif // VPOINTF_H diff --git a/src/libs/vgeometry/vpointf_p.h b/src/libs/vgeometry/vpointf_p.h index 9affe3a94..6061c8c3e 100644 --- a/src/libs/vgeometry/vpointf_p.h +++ b/src/libs/vgeometry/vpointf_p.h @@ -31,12 +31,11 @@ #include #include "vgeometrydef.h" +#include "../vmisc/diagnostic.h" #include -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VPointFData : public QSharedData { @@ -83,8 +82,6 @@ private: VPointFData::~VPointFData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VPOINTF_P_H diff --git a/src/libs/vgeometry/vspline_p.h b/src/libs/vgeometry/vspline_p.h index c8d59e6ba..43d8fb532 100644 --- a/src/libs/vgeometry/vspline_p.h +++ b/src/libs/vgeometry/vspline_p.h @@ -36,10 +36,8 @@ #include "vpointf.h" #include "../vmisc/vabstractapplication.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VSplineData : public QSharedData { @@ -209,8 +207,6 @@ qreal VSplineData::GetL(const QPointF &p1, const QPointF &p4, qreal kCurve) return kCurve * radius * 4 / 3 * qTan( angle * M_PI_4 / 180.0 ); } -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VSPLINE_P_H diff --git a/src/libs/vgeometry/vsplinepath_p.h b/src/libs/vgeometry/vsplinepath_p.h index 817b4c87c..4e18d9bbb 100644 --- a/src/libs/vgeometry/vsplinepath_p.h +++ b/src/libs/vgeometry/vsplinepath_p.h @@ -32,10 +32,8 @@ #include #include "vsplinepoint.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VSplinePathData : public QSharedData { @@ -64,8 +62,6 @@ private: VSplinePathData::~VSplinePathData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VSPLINEPATH_P_H diff --git a/src/libs/vgeometry/vsplinepoint_p.h b/src/libs/vgeometry/vsplinepoint_p.h index 909d98366..3addb8385 100644 --- a/src/libs/vgeometry/vsplinepoint_p.h +++ b/src/libs/vgeometry/vsplinepoint_p.h @@ -35,10 +35,8 @@ #include "vpointf.h" #include "../vmisc/def.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VFSplinePointData : public QSharedData { @@ -178,8 +176,6 @@ private: VSplinePointData::~VSplinePointData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VSPLINEPOINT_P_H diff --git a/src/libs/vlayout/vabstractdetail_p.h b/src/libs/vlayout/vabstractdetail_p.h index e59d6f159..a84bb5980 100644 --- a/src/libs/vlayout/vabstractdetail_p.h +++ b/src/libs/vlayout/vabstractdetail_p.h @@ -32,10 +32,10 @@ #include #include -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VAbstractDetailData : public QSharedData { @@ -68,8 +68,6 @@ private: VAbstractDetailData &operator=(const VAbstractDetailData &) Q_DECL_EQ_DELETE; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VABSTRACTDETAIL_P_H diff --git a/src/libs/vlayout/vbank.cpp b/src/libs/vlayout/vbank.cpp index e127da03c..8bb37c5d4 100644 --- a/src/libs/vlayout/vbank.cpp +++ b/src/libs/vlayout/vbank.cpp @@ -34,21 +34,13 @@ #include #include -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(lBank, "layout.bank") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP // An annoying char define, from the Windows team in // #define small char diff --git a/src/libs/vlayout/vcontour_p.h b/src/libs/vlayout/vcontour_p.h index 7eec46b3b..84c09d145 100644 --- a/src/libs/vlayout/vcontour_p.h +++ b/src/libs/vlayout/vcontour_p.h @@ -32,10 +32,10 @@ #include #include -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VContourData : public QSharedData { @@ -70,8 +70,6 @@ private: VContourData &operator=(const VContourData &) Q_DECL_EQ_DELETE; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VCONTOUR_P_H diff --git a/src/libs/vlayout/vlayoutdetail_p.h b/src/libs/vlayout/vlayoutdetail_p.h index 01995de98..efbdf8ca6 100644 --- a/src/libs/vlayout/vlayoutdetail_p.h +++ b/src/libs/vlayout/vlayoutdetail_p.h @@ -38,11 +38,8 @@ #include "../vpatterndb/vpatterninfogeometry.h" #include "vtextmanager.h" - -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VLayoutDetailData : public QSharedData { @@ -100,8 +97,6 @@ private: VLayoutDetailData &operator=(const VLayoutDetailData &) Q_DECL_EQ_DELETE; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VLAYOUTDETAIL_P_H diff --git a/src/libs/vlayout/vlayoutpaper_p.h b/src/libs/vlayout/vlayoutpaper_p.h index c6423b573..373ffff84 100644 --- a/src/libs/vlayout/vlayoutpaper_p.h +++ b/src/libs/vlayout/vlayoutpaper_p.h @@ -36,10 +36,8 @@ #include "vlayoutdetail.h" #include "vcontour.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VLayoutPaperData : public QSharedData { @@ -79,8 +77,6 @@ private: VLayoutPaperData &operator=(const VLayoutPaperData &) Q_DECL_EQ_DELETE; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VLAYOUTPAPER_P_H diff --git a/src/libs/vmisc/backport/qcommandlineoption.cpp b/src/libs/vmisc/backport/qcommandlineoption.cpp index a27b4e1d2..aa8000cf8 100644 --- a/src/libs/vmisc/backport/qcommandlineoption.cpp +++ b/src/libs/vmisc/backport/qcommandlineoption.cpp @@ -25,10 +25,10 @@ #if QT_VERSION < QT_VERSION_CHECK(5, 2, 0) -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class QCommandLineOptionPrivate : public QSharedData { @@ -52,9 +52,7 @@ public: QStringList defaultValues; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP /*! \since 5.2 diff --git a/src/libs/vmisc/backport/qcommandlineoption.h b/src/libs/vmisc/backport/qcommandlineoption.h index b2f044fcb..9d1edf8e5 100644 --- a/src/libs/vmisc/backport/qcommandlineoption.h +++ b/src/libs/vmisc/backport/qcommandlineoption.h @@ -26,10 +26,10 @@ #if QT_VERSION < QT_VERSION_CHECK(5, 2, 0) -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class QCommandLineOptionPrivate; @@ -71,9 +71,7 @@ private: QSharedDataPointer d; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP Q_DECLARE_SHARED(QCommandLineOption) diff --git a/src/libs/vmisc/backport/qcommandlineparser.cpp b/src/libs/vmisc/backport/qcommandlineparser.cpp index 7d9ab7128..ff70eaae1 100644 --- a/src/libs/vmisc/backport/qcommandlineparser.cpp +++ b/src/libs/vmisc/backport/qcommandlineparser.cpp @@ -29,12 +29,12 @@ #if QT_VERSION < QT_VERSION_CHECK(5, 2, 0) -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" - #pragma GCC diagnostic ignored "-Wswitch-default" - #pragma GCC diagnostic ignored "-Wsuggest-attribute=noreturn" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") +QT_WARNING_DISABLE_GCC("-Wswitch-default") +QT_WARNING_DISABLE_GCC("-Wsuggest-attribute=noreturn") typedef QHash NameHash_t; @@ -891,9 +891,6 @@ QString QCommandLineParserPrivate::helpText() const return text; } - -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif //QT_VERSION < QT_VERSION_CHECK(5, 2, 0) diff --git a/src/libs/vmisc/backport/qcommandlineparser.h b/src/libs/vmisc/backport/qcommandlineparser.h index 9842a1ce2..7e9721fdf 100644 --- a/src/libs/vmisc/backport/qcommandlineparser.h +++ b/src/libs/vmisc/backport/qcommandlineparser.h @@ -29,10 +29,10 @@ class QCommandLineParserPrivate; class QCoreApplication; -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class QCommandLineParser { @@ -83,9 +83,7 @@ private: QCommandLineParserPrivate * const d; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif //QT_VERSION < QT_VERSION_CHECK(5, 2, 0) diff --git a/src/libs/vmisc/qxtcsvmodel.cpp b/src/libs/vmisc/qxtcsvmodel.cpp index 2b728f797..049e6bd65 100644 --- a/src/libs/vmisc/qxtcsvmodel.cpp +++ b/src/libs/vmisc/qxtcsvmodel.cpp @@ -39,6 +39,8 @@ #include #include +#include "../vmisc/diagnostic.h" + class QxtCsvModelPrivate : public QxtPrivate { public: @@ -52,10 +54,8 @@ public: QxtCsvModel::QuoteMode quoteMode; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") /*! Creates an empty QxtCsvModel with parent \a parent. @@ -98,9 +98,7 @@ QxtCsvModel::QxtCsvModel(const QString &filename, QObject *parent, bool withHead setSource(&src, withHeader, separator); } -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP QxtCsvModel::~QxtCsvModel() {} diff --git a/src/libs/vmisc/vlockguard.h b/src/libs/vmisc/vlockguard.h index a266ff2a4..48576827c 100644 --- a/src/libs/vmisc/vlockguard.h +++ b/src/libs/vmisc/vlockguard.h @@ -34,6 +34,8 @@ #include #include +#include "../vmisc/diagnostic.h" + #if QT_VERSION >= QT_VERSION_CHECK(5, 1, 0) #include #include @@ -195,10 +197,8 @@ bool VLockGuard::TryLock(const QString &lockName, int stale, int timeou //use pointer and function below to persistent things like class-member, because lock is taken by constructor //helper functions allow to write shorter creating and setting new lock-pointer -#if defined (Q_CC_INTEL) -#pragma warning( push ) -#pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_INTEL(1418) template void VlpCreateLock(std::shared_ptr>& r, const QString& lockName, int stale = 0, int timeout = 0) @@ -220,8 +220,6 @@ void VlpCreateLock(std::shared_ptr>& r, const QString& lockN r.reset(new VLockGuard(lockName, a, d, stale, timeout)); } -#if defined(Q_CC_INTEL) -#pragma warning( pop ) -#endif +QT_WARNING_POP #endif // VLOCKGUARD_H diff --git a/src/libs/vobj/delaunay.cpp b/src/libs/vobj/delaunay.cpp index 9536de729..1bfc315be 100644 --- a/src/libs/vobj/delaunay.cpp +++ b/src/libs/vobj/delaunay.cpp @@ -25,12 +25,11 @@ #include #include "delaunay.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wold-style-cast" - #pragma GCC diagnostic ignored "-Wcast-qual" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wold-style-cast") +QT_WARNING_DISABLE_GCC("-Wcast-qual") #if PREDICATE == EXACT_PREDICATE extern void exactinit(); @@ -1083,6 +1082,4 @@ void delaunay2d_release(delaunay2d_t *del) { free(del); } -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP diff --git a/src/libs/vobj/vobjengine.cpp b/src/libs/vobj/vobjengine.cpp index 3a84984b7..84d611829 100644 --- a/src/libs/vobj/vobjengine.cpp +++ b/src/libs/vobj/vobjengine.cpp @@ -27,6 +27,7 @@ *************************************************************************/ #include "vobjengine.h" +#include "../vmisc/diagnostic.h" #include #include @@ -44,14 +45,10 @@ //--------------------------------------------------------------------------------------------------------------------- static inline QPaintEngine::PaintEngineFeatures svgEngineFeatures() { -#if defined(Q_CC_CLANG) -#pragma clang diagnostic push -#pragma clang diagnostic ignored "-Wsign-conversion" -#elif defined (Q_CC_INTEL) -#pragma warning( push ) -#pragma warning( disable: 68 ) -#pragma warning( disable: 2022 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wsign-conversion") +QT_WARNING_DISABLE_INTEL(68) +QT_WARNING_DISABLE_INTEL(2022) return QPaintEngine::PaintEngineFeatures( QPaintEngine::AllFeatures @@ -60,9 +57,7 @@ static inline QPaintEngine::PaintEngineFeatures svgEngineFeatures() & ~QPaintEngine::ConicalGradientFill & ~QPaintEngine::PorterDuff); -#if defined(Q_CC_CLANG) -#pragma clang diagnostic pop -#endif +QT_WARNING_POP } //--------------------------------------------------------------------------------------------------------------------- diff --git a/src/libs/vpatterndb/variables/varcradius_p.h b/src/libs/vpatterndb/variables/varcradius_p.h index cba6d7a40..58f904dab 100644 --- a/src/libs/vpatterndb/variables/varcradius_p.h +++ b/src/libs/vpatterndb/variables/varcradius_p.h @@ -31,10 +31,10 @@ #include -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VArcRadiusData : public QSharedData { @@ -63,8 +63,6 @@ private: VArcRadiusData::~VArcRadiusData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VARCRADIUSDATA_H diff --git a/src/libs/vpatterndb/variables/vcurvevariable_p.h b/src/libs/vpatterndb/variables/vcurvevariable_p.h index bf3152ce9..185b57e57 100644 --- a/src/libs/vpatterndb/variables/vcurvevariable_p.h +++ b/src/libs/vpatterndb/variables/vcurvevariable_p.h @@ -32,11 +32,10 @@ #include #include "../ifc/ifcdef.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VCurveVariableData : public QSharedData { @@ -66,8 +65,6 @@ private: VCurveVariableData::~VCurveVariableData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VCURVELENGTH_P_H diff --git a/src/libs/vpatterndb/variables/vincrement_p.h b/src/libs/vpatterndb/variables/vincrement_p.h index 826b400d3..78af443fc 100644 --- a/src/libs/vpatterndb/variables/vincrement_p.h +++ b/src/libs/vpatterndb/variables/vincrement_p.h @@ -33,11 +33,10 @@ #include "../ifc/ifcdef.h" #include "../vcontainer.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VIncrementData : public QSharedData { @@ -70,8 +69,6 @@ private: VIncrementData::~VIncrementData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VINCREMENT_P_H diff --git a/src/libs/vpatterndb/variables/vinternalvariable_p.h b/src/libs/vpatterndb/variables/vinternalvariable_p.h index b3f9c5b5d..69ddf6566 100644 --- a/src/libs/vpatterndb/variables/vinternalvariable_p.h +++ b/src/libs/vpatterndb/variables/vinternalvariable_p.h @@ -31,11 +31,10 @@ #include #include "../vmisc/def.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VInternalVariableData : public QSharedData { @@ -65,8 +64,6 @@ private: VInternalVariableData::~VInternalVariableData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VINTERNALVARIABLE_P_H diff --git a/src/libs/vpatterndb/variables/vlineangle_p.h b/src/libs/vpatterndb/variables/vlineangle_p.h index aec3948f0..969581f2f 100644 --- a/src/libs/vpatterndb/variables/vlineangle_p.h +++ b/src/libs/vpatterndb/variables/vlineangle_p.h @@ -32,11 +32,10 @@ #include #include "../ifc/ifcdef.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VLineAngleData : public QSharedData { @@ -66,8 +65,6 @@ private: VLineAngleData::~VLineAngleData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VLINEANGLE_P_H diff --git a/src/libs/vpatterndb/variables/vlinelength_p.h b/src/libs/vpatterndb/variables/vlinelength_p.h index 2a38a2736..9f14a4f9f 100644 --- a/src/libs/vpatterndb/variables/vlinelength_p.h +++ b/src/libs/vpatterndb/variables/vlinelength_p.h @@ -32,11 +32,10 @@ #include #include "../ifc/ifcdef.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VLengthLineData : public QSharedData { @@ -67,8 +66,6 @@ private: VLengthLineData::~VLengthLineData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VLINELENGTH_P_H diff --git a/src/libs/vpatterndb/variables/vmeasurement_p.h b/src/libs/vpatterndb/variables/vmeasurement_p.h index 50017485f..5b362090a 100644 --- a/src/libs/vpatterndb/variables/vmeasurement_p.h +++ b/src/libs/vpatterndb/variables/vmeasurement_p.h @@ -32,11 +32,10 @@ #include #include "../vcontainer.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VMeasurementData : public QSharedData { @@ -73,8 +72,6 @@ private: VMeasurementData::~VMeasurementData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VMEASUREMENT_P_H diff --git a/src/libs/vpatterndb/variables/vvariable_p.h b/src/libs/vpatterndb/variables/vvariable_p.h index 01e17d4f5..f3bff1f99 100644 --- a/src/libs/vpatterndb/variables/vvariable_p.h +++ b/src/libs/vpatterndb/variables/vvariable_p.h @@ -31,10 +31,10 @@ #include -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +#include "../vmisc/diagnostic.h" + +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VVariableData : public QSharedData { @@ -83,8 +83,6 @@ private: VVariableData::~VVariableData() {} -#ifdef Q_CC_GNU -#pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VVARIABLE_P_H diff --git a/src/libs/vpatterndb/vcontainer.cpp b/src/libs/vpatterndb/vcontainer.cpp index 1d6fa8fe1..5e9252d12 100644 --- a/src/libs/vpatterndb/vcontainer.cpp +++ b/src/libs/vpatterndb/vcontainer.cpp @@ -37,21 +37,13 @@ #include #include -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(vCon, "v.container") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP quint32 VContainer::_id = NULL_ID; qreal VContainer::_size = 50; diff --git a/src/libs/vpatterndb/vcontainer.h b/src/libs/vpatterndb/vcontainer.h index 2309dccb0..bb09d0f00 100644 --- a/src/libs/vpatterndb/vcontainer.h +++ b/src/libs/vpatterndb/vcontainer.h @@ -35,6 +35,7 @@ #include "../ifc/exception/vexceptionbadid.h" #include "../vgeometry/vabstractcurve.h" #include "../vgeometry/vabstractcubicbezierpath.h" +#include "../vmisc/diagnostic.h" #include "vtranslatevars.h" #include @@ -42,13 +43,9 @@ #include #include -#if defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 2021 ) -#elif defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") +QT_WARNING_DISABLE_INTEL(2021) class VContainerData : public QSharedData //-V690 { @@ -88,11 +85,7 @@ private: VContainerData &operator=(const VContainerData &) Q_DECL_EQ_DELETE; }; -#if defined(Q_CC_INTEL) - #pragma warning( pop ) -#elif defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP /** * @brief The VContainer class container of all variables. diff --git a/src/libs/vpatterndb/vdetail_p.h b/src/libs/vpatterndb/vdetail_p.h index 4092cec9a..7e256b9e5 100644 --- a/src/libs/vpatterndb/vdetail_p.h +++ b/src/libs/vpatterndb/vdetail_p.h @@ -34,11 +34,10 @@ #include "vpatternpiecedata.h" #include "vpatterninfogeometry.h" #include "../ifc/ifcdef.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VDetailData : public QSharedData { @@ -81,8 +80,6 @@ private: VDetailData &operator=(const VDetailData &) Q_DECL_EQ_DELETE; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VDETAIL_P_H diff --git a/src/libs/vpatterndb/vnodedetail_p.h b/src/libs/vpatterndb/vnodedetail_p.h index 82d634469..6f2eb2b1f 100644 --- a/src/libs/vpatterndb/vnodedetail_p.h +++ b/src/libs/vpatterndb/vnodedetail_p.h @@ -31,11 +31,10 @@ #include #include "../ifc/ifcdef.h" +#include "../vmisc/diagnostic.h" -#ifdef Q_CC_GNU - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Weffc++" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Weffc++") class VNodeDetailData : public QSharedData { @@ -84,8 +83,6 @@ private: VNodeDetailData &operator=(const VNodeDetailData &) Q_DECL_EQ_DELETE; }; -#ifdef Q_CC_GNU - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP #endif // VNODEDETAIL_P_H diff --git a/src/libs/vpropertyexplorer/vabstractpropertyfactory.h b/src/libs/vpropertyexplorer/vabstractpropertyfactory.h index 0913d9f36..b8b1068c3 100644 --- a/src/libs/vpropertyexplorer/vabstractpropertyfactory.h +++ b/src/libs/vpropertyexplorer/vabstractpropertyfactory.h @@ -22,6 +22,7 @@ #define VABSTRACTPROPERTYFACTORY_H #include "vpropertyexplorer_global.h" +#include "../vmisc/diagnostic.h" #include namespace VPE @@ -29,10 +30,8 @@ namespace VPE class VProperty; -#ifdef Q_CC_CLANG - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wweak-vtables" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wweak-vtables") class VPROPERTYEXPLORERSHARED_EXPORT VAbstractPropertyFactory { @@ -47,9 +46,7 @@ public: virtual VProperty* createProperty(const QString& type, const QString &name) = 0; }; -#ifdef Q_CC_CLANG - #pragma clang diagnostic pop -#endif +QT_WARNING_POP } diff --git a/src/libs/vpropertyexplorer/vpropertyformview_p.h b/src/libs/vpropertyexplorer/vpropertyformview_p.h index dfb145bac..4d87e4927 100644 --- a/src/libs/vpropertyexplorer/vpropertyformview_p.h +++ b/src/libs/vpropertyexplorer/vpropertyformview_p.h @@ -24,6 +24,7 @@ // ONLY INCLUDE THIS IN .CPP FILES #include "vpropertyformwidget_p.h" +#include "../vmisc/diagnostic.h" namespace VPE { @@ -31,10 +32,8 @@ namespace VPE class VPropertyModel; class VPropertySet; -#ifdef Q_CC_CLANG - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wweak-vtables" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wweak-vtables") class VPropertyFormViewPrivate : public VPropertyFormWidgetPrivate { @@ -72,9 +71,7 @@ private: Q_DISABLE_COPY(VPropertyFormViewPrivate) }; -#ifdef Q_CC_CLANG - #pragma clang diagnostic pop -#endif +QT_WARNING_POP } diff --git a/src/libs/vpropertyexplorer/vpropertyformwidget_p.h b/src/libs/vpropertyexplorer/vpropertyformwidget_p.h index 71a1e005d..6a83149a9 100644 --- a/src/libs/vpropertyexplorer/vpropertyformwidget_p.h +++ b/src/libs/vpropertyexplorer/vpropertyformwidget_p.h @@ -25,14 +25,13 @@ #include #include "vproperty.h" +#include "../vmisc/diagnostic.h" namespace VPE { -#ifdef Q_CC_CLANG - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wweak-vtables" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wweak-vtables") class VPropertyFormWidgetPrivate { @@ -71,9 +70,7 @@ public: virtual ~VPropertyFormWidgetPrivate() {} }; -#ifdef Q_CC_CLANG - #pragma clang diagnostic pop -#endif +QT_WARNING_POP } diff --git a/src/libs/vpropertyexplorer/vwidgetproperty_p.h b/src/libs/vpropertyexplorer/vwidgetproperty_p.h index ce93a6135..8925ac872 100644 --- a/src/libs/vpropertyexplorer/vwidgetproperty_p.h +++ b/src/libs/vpropertyexplorer/vwidgetproperty_p.h @@ -24,6 +24,7 @@ // ONLY INCLUDE THIS IN .CPP FILES #include "vproperty_p.h" +#include "../vmisc/diagnostic.h" #include #include @@ -31,10 +32,8 @@ namespace VPE { -#ifdef Q_CC_CLANG - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wweak-vtables" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wweak-vtables") class VWidgetPropertyPrivate : public VPropertyPrivate { @@ -60,9 +59,7 @@ public: } }; -#ifdef Q_CC_CLANG - #pragma clang diagnostic pop -#endif +QT_WARNING_POP } diff --git a/src/libs/vtools/tools/drawTools/operation/vtoolrotation.cpp b/src/libs/vtools/tools/drawTools/operation/vtoolrotation.cpp index 9e13392be..7ba3ac86b 100644 --- a/src/libs/vtools/tools/drawTools/operation/vtoolrotation.cpp +++ b/src/libs/vtools/tools/drawTools/operation/vtoolrotation.cpp @@ -68,10 +68,8 @@ VToolRotation::VToolRotation(VAbstractPattern *doc, VContainer *data, quint32 id // This check helps to find missed objects in the switch Q_STATIC_ASSERT_X(static_cast(GOType::Unknown) == 7, "Not all objects were handled."); -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") switch(static_cast(obj->getType())) { case GOType::Point: @@ -124,9 +122,7 @@ VToolRotation::VToolRotation(VAbstractPattern *doc, VContainer *data, quint32 id case GOType::Unknown: break; } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP } ToolCreation(typeCreation); @@ -198,10 +194,8 @@ VToolRotation *VToolRotation::Create(const quint32 _id, const quint32 &origin, Q // This check helps to find missed objects in the switch Q_STATIC_ASSERT_X(static_cast(GOType::Unknown) == 7, "Not all objects were handled."); -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") switch(static_cast(obj->getType())) { case GOType::Point: @@ -229,9 +223,7 @@ VToolRotation *VToolRotation::Create(const quint32 _id, const quint32 &origin, Q case GOType::Unknown: break; } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP } } else @@ -244,10 +236,8 @@ VToolRotation *VToolRotation::Create(const quint32 _id, const quint32 &origin, Q // This check helps to find missed objects in the switch Q_STATIC_ASSERT_X(static_cast(GOType::Unknown) == 7, "Not all objects were handled."); -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") switch(static_cast(obj->getType())) { case GOType::Point: @@ -276,9 +266,7 @@ VToolRotation *VToolRotation::Create(const quint32 _id, const quint32 &origin, Q case GOType::Unknown: break; } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP } if (parse != Document::FullParse) { diff --git a/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/toollinepoint/vtoolcurveintersectaxis.cpp b/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/toollinepoint/vtoolcurveintersectaxis.cpp index 8108b1976..40449cf20 100644 --- a/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/toollinepoint/vtoolcurveintersectaxis.cpp +++ b/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/toollinepoint/vtoolcurveintersectaxis.cpp @@ -299,10 +299,8 @@ void VToolCurveIntersectAxis::SetVisualization() } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") void VToolCurveIntersectAxis::InitSegments(const GOType &curveType, qreal segLength, const VPointF *p, quint32 curveId, VContainer *data) { @@ -444,6 +442,4 @@ void VToolCurveIntersectAxis::InitSegments(const GOType &curveType, qreal segLen } } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP diff --git a/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/vtoolsinglepoint.cpp b/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/vtoolsinglepoint.cpp index 3778ffffe..ad7f2acac 100644 --- a/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/vtoolsinglepoint.cpp +++ b/src/libs/vtools/tools/drawTools/toolpoint/toolsinglepoint/vtoolsinglepoint.cpp @@ -34,21 +34,13 @@ #include -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(vToolSinglePoint, "v.toolSinglePoint") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- /** diff --git a/src/libs/vtools/tools/vtooluniondetails.cpp b/src/libs/vtools/tools/vtooluniondetails.cpp index 7e650b141..769c77b82 100644 --- a/src/libs/vtools/tools/vtooluniondetails.cpp +++ b/src/libs/vtools/tools/vtooluniondetails.cpp @@ -49,21 +49,13 @@ const QString VToolUnionDetails::AttrNodeType = QStringLiteral("nodeType"); const QString VToolUnionDetails::NodeTypeContour = QStringLiteral("Contour"); const QString VToolUnionDetails::NodeTypeModeling = QStringLiteral("Modeling"); -#if defined(Q_CC_CLANG) - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wmissing-prototypes" -#elif defined(Q_CC_INTEL) - #pragma warning( push ) - #pragma warning( disable: 1418 ) -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_CLANG("-Wmissing-prototypes") +QT_WARNING_DISABLE_INTEL(1418) Q_LOGGING_CATEGORY(vToolUnion, "v.toolUnion") -#if defined(Q_CC_CLANG) - #pragma clang diagnostic pop -#elif defined(Q_CC_INTEL) - #pragma warning( pop ) -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- /** diff --git a/src/libs/vtools/visualization/line/vistoolrotation.cpp b/src/libs/vtools/visualization/line/vistoolrotation.cpp index 7be9fd8f1..70a47d229 100644 --- a/src/libs/vtools/visualization/line/vistoolrotation.cpp +++ b/src/libs/vtools/visualization/line/vistoolrotation.cpp @@ -63,10 +63,8 @@ VisToolRotation::~VisToolRotation() } //--------------------------------------------------------------------------------------------------------------------- -#if defined(Q_CC_GNU) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wswitch-default" -#endif +QT_WARNING_PUSH +QT_WARNING_DISABLE_GCC("-Wswitch-default") void VisToolRotation::RefreshGeometry() { @@ -178,9 +176,7 @@ void VisToolRotation::RefreshGeometry() } } -#if defined(Q_CC_GNU) - #pragma GCC diagnostic pop -#endif +QT_WARNING_POP //--------------------------------------------------------------------------------------------------------------------- void VisToolRotation::SetObjects(QVector objects)