This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/49813] New: sinh vs asinh vs constexpr


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49813

           Summary: sinh vs asinh vs constexpr
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: paolo.carlini@oracle.com


Hi. This issue, pointed out in private email by Vincenzo, puzzles me, I'm not
even sure whether it's a C++ proper or an optimization issue related to the way
we are lately able to optimize at compile time, mathematical functions of
compile time constant arguments. To be safe, I'm adding in CC both Jason and
Richi.

(Note, I'm using math.h instead of cmath for avoidance of doubt that this may
have to do with the library...)

//////////////

#include <math.h>

int main()
{
  constexpr double ds  = sinh(1.0);   // Ok
  constexpr double das = asinh(1.0);  // Doesn't compile.
}


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]