diff options
author | Kurt Pattyn <pattyn.kurt@gmail.com> | 2014-01-12 17:58:56 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-01-21 09:32:11 +0100 |
commit | 5f52974860a9fc62ec5e7c56853156fed01b3aed (patch) | |
tree | 6045ce11c7c8ae2e44786c2bcc194eb3e2b348f7 /src/corelib/tools/qvector.h | |
parent | f54873c81a21084ae0671498c7b295615789ac32 (diff) |
Retain compiler warning state
Added push and pop pragma warning statements. Suppression of warnings
should not propagate to user code. Therefore, suppression of warnings
is restricted to the file where it is used.
Change-Id: Ib7973cbc0205ebbe75e002d035e44fd9b447460f
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Diffstat (limited to 'src/corelib/tools/qvector.h')
-rw-r--r-- | src/corelib/tools/qvector.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/corelib/tools/qvector.h b/src/corelib/tools/qvector.h index 505e1a32e4..075e8e83e8 100644 --- a/src/corelib/tools/qvector.h +++ b/src/corelib/tools/qvector.h @@ -254,7 +254,10 @@ private: }; #ifdef Q_CC_MSVC -# pragma warning ( disable : 4345 ) // behavior change: an object of POD type constructed with an initializer of the form () will be default-initialized +// behavior change: an object of POD type constructed with an initializer of the form () +// will be default-initialized +# pragma warning ( push ) +# pragma warning ( disable : 4345 ) #endif template <typename T> @@ -270,7 +273,7 @@ void QVector<T>::defaultConstruct(T *from, T *to) } #ifdef Q_CC_MSVC -# pragma warning ( default: 4345 ) +# pragma warning ( pop ) #endif template <typename T> |