diff options
author | Brad King <brad.king@kitware.com> | 2013-08-07 12:18:32 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2013-08-07 12:18:32 (GMT) |
commit | 09b147b3a7c864c3d9c044d970235a49f3d69b7a (patch) | |
tree | d8381f3dd2fe35ba7622e007ee951062d4bcee32 /Source/kwsys/auto_ptr.hxx.in | |
parent | 726fa61b59c20ea657091fa870bf7eba77dfaa75 (diff) | |
parent | ce6eac8b58b0230cd1d8ee100a27973e5354a5c4 (diff) | |
download | CMake-09b147b3a7c864c3d9c044d970235a49f3d69b7a.zip CMake-09b147b3a7c864c3d9c044d970235a49f3d69b7a.tar.gz CMake-09b147b3a7c864c3d9c044d970235a49f3d69b7a.tar.bz2 |
Merge branch 'upstream-kwsys' into update-kwsys
Diffstat (limited to 'Source/kwsys/auto_ptr.hxx.in')
-rw-r--r-- | Source/kwsys/auto_ptr.hxx.in | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Source/kwsys/auto_ptr.hxx.in b/Source/kwsys/auto_ptr.hxx.in index 857b1db..ad9654c 100644 --- a/Source/kwsys/auto_ptr.hxx.in +++ b/Source/kwsys/auto_ptr.hxx.in @@ -31,6 +31,17 @@ # define @KWSYS_NAMESPACE@_AUTO_PTR_CAST(a) a #endif +// In C++11, clang will warn about using dynamic exception specifications +// as they are deprecated. But as this class is trying to faithfully +// mimic std::auto_ptr, we want to keep the 'throw()' decorations below. +// So we suppress the warning. +#if defined(__clang__) && defined(__has_warning) +# if __has_warning("-Wdeprecated") +# pragma clang diagnostic push +# pragma clang diagnostic ignored "-Wdeprecated" +# endif +#endif + namespace @KWSYS_NAMESPACE@ { @@ -198,4 +209,11 @@ public: } // namespace @KWSYS_NAMESPACE@ +// Undo warning suppression. +#if defined(__clang__) && defined(__has_warning) +# if __has_warning("-Wdeprecated") +# pragma clang diagnostic pop +# endif +#endif + #endif |