Test case fix for std::complex and non-floating types deprecation

From Visual Studio 2022:

warning C4996: 'std::complex<int>::complex': warning STL4037: The effect of instantiating the template std::complex for any type other than float, double, or long double is unspecified. You can define _SILENCE_NONFLOATING_COMPLEX_DEPRECATION_WARNING to suppress this warning.
This commit is contained in:
William S Fulton 2022-11-26 10:18:11 +00:00
parent ecf05445b9
commit 637e297672
2 changed files with 4 additions and 4 deletions

View File

@ -49,7 +49,7 @@
%inline %{ %inline %{
struct A{ struct A{
A(std::complex<int> i, double d=0.0) {} A(std::complex<double> i, double d=0.0) {}
A(int i, bool j=false) {} A(int i, bool j=false) {}
virtual ~A() {} virtual ~A() {}
@ -60,7 +60,7 @@
namespace hi { namespace hi {
struct A1 : public A { struct A1 : public A {
A1(std::complex<int> i, double d=0.0) : A(i, d) {} A1(std::complex<double> i, double d=0.0) : A(i, d) {}
A1(int i, bool j=false) : A(i, j) {} A1(int i, bool j=false) : A(i, j) {}
virtual int ff(int i = 0) {return i;} virtual int ff(int i = 0) {return i;}

View File

@ -54,7 +54,7 @@
%inline %{ %inline %{
struct A{ struct A{
A(std::complex<int> i, double d=0.0) {} A(std::complex<double> i, double d=0.0) {}
A(int i, bool j=false) {} A(int i, bool j=false) {}
virtual ~A() {} virtual ~A() {}
@ -65,7 +65,7 @@
namespace hi { namespace hi {
struct A1 : public A { struct A1 : public A {
A1(std::complex<int> i, double d=0.0) : A(i, d) {} A1(std::complex<double> i, double d=0.0) : A(i, d) {}
A1(int i, bool j=false) : A(i, j) {} A1(int i, bool j=false) : A(i, j) {}
virtual int ff(int i = 0) {return i;} virtual int ff(int i = 0) {return i;}