summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/pr14649-1.c
blob: 34f42f08f2cadef0f5c3a6b5663d005b0ed58094 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* PR c/14649 */
/* { dg-do compile } */
/* { dg-options "-O2" } */

double atan(double);

const double pi = 4*atan(1.0);  /* { dg-warning "not a constant expression" } */

const double ok = 4*__builtin_atan(1.0);

double foo()
{
  double ok2 = 4*atan(1.0);
  return ok2;
}