Use #pragma warning(push) and pop to control our warnings
Using "default" means "reset to default compiler settings", not "revert to command-line settings". And even if it did, it's possible some other headers by the user toggled the settings. We shouldn't affect that. Task-number: QTBUG-35622 Change-Id: If7c4bd0cc8c210f88ee89e3fa2dd3b7194ad77bb Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>bb10
parent
de61c78807
commit
e6abf372c6
|
|
@ -327,6 +327,7 @@ inline void QImage::setPixel(const QPoint &pt, uint index_or_rgb) { setPixel(pt.
|
|||
# pragma GCC diagnostic push
|
||||
# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
#elif defined(Q_CC_MSVC)
|
||||
# pragma warning(push)
|
||||
# pragma warning(disable: 4996)
|
||||
#endif
|
||||
|
||||
|
|
@ -403,7 +404,7 @@ inline void QImage::setText(const char* key, const char* lang, const QString &s)
|
|||
#if defined(Q_CC_GNU) && !defined(Q_CC_INTEL) && (__GNUC__ * 100 + __GNUC_MINOR__ >= 406)
|
||||
# pragma GCC diagnostic pop
|
||||
#elif defined(Q_CC_MSVC)
|
||||
# pragma warning(default: 4996)
|
||||
# pragma warning(pop)
|
||||
#endif
|
||||
|
||||
inline int QImage::numColors() const
|
||||
|
|
|
|||
Loading…
Reference in New Issue