Openlibm: Difference between revisions

517 bytes added ,  28 July 2022
No edit summary
Line 48: Line 48:


===Testing of bug {{bug|55538}}===
===Testing of bug {{bug|55538}}===
*;CODE SOURCE: [https://github.com/shreyaswikriti/BugTesting/blob/main/bug%2355538.cc C++ PROGRAM]
*;CODE SOURCE:
 
<syntaxhighlight lang="C++">
#include <complex>
#include <limits>
#include <iostream>
 
int
main (int argc, char *argv[])
{
  double x = 10.0;
  std::complex<double> y (std::numeric_limits<double>::infinity (), 1.0);
 
  std::complex<double> z1 = std::pow (x, y);
  std::complex<double> z2 = std::pow (std::complex<double> (x), y);
  std::complex<double> z3 = std::exp (y * std::log (x));
  std::complex<double> z4 = std::exp (y * std::log (std::complex<double> (x)));
 
  std::cout << z1 << ", "
            << z2 << ", "
            << z3 << ", "
            << z4 << std::endl;
}
</syntaxhighlight>
 


*;Output Expected :  
*;Output Expected :