From d58e62913081d3667605fd3fa9d525d4e378dd00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20S=C3=A1nchez?= Date: Thu, 24 Feb 2022 21:20:49 +0000 Subject: [PATCH] Disable deprecated warnings for SVD tests on MSVC. --- test/bdcsvd.cpp | 4 +++- test/jacobisvd.cpp | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/test/bdcsvd.cpp b/test/bdcsvd.cpp index 0714a7729..434bd4eb8 100644 --- a/test/bdcsvd.cpp +++ b/test/bdcsvd.cpp @@ -13,8 +13,10 @@ // We explicitly disable deprecated declarations for this set of tests // because we purposely verify assertions for the deprecated SVD runtime // option behavior. -#ifdef __GNUC__ +#if defined(__GNUC__) #pragma GCC diagnostic ignored "-Wdeprecated-declarations" +#elif defined(_MSC_VER) +#pragma warning( disable : 4996 ) #endif // discard stack allocation as that too bypasses malloc diff --git a/test/jacobisvd.cpp b/test/jacobisvd.cpp index 833aee6a5..fab588204 100644 --- a/test/jacobisvd.cpp +++ b/test/jacobisvd.cpp @@ -11,8 +11,10 @@ // We explicitly disable deprecated declarations for this set of tests // because we purposely verify assertions for the deprecated SVD runtime // option behavior. -#ifdef __GNUC__ +#if defined(__GNUC__) #pragma GCC diagnostic ignored "-Wdeprecated-declarations" +#elif defined(_MSC_VER) +#pragma warning( disable : 4996 ) #endif // discard stack allocation as that too bypasses malloc