PR libstdc++/78179 run long double tests separately
[official-gcc.git] / libstdc++-v3 / testsuite / 26_numerics / headers / cmath / c_math_dynamic.cc
blob67fc2d9484c1c93b893e0f1bafa0ef7635eb70a2
1 // Inspired by libstdc++/7680 & 26_numerics/c_math.cc, 2003-04-12 ljr
3 // Copyright (C) 2003-2018 Free Software Foundation, Inc.
4 //
5 // This file is part of the GNU ISO C++ Library. This library is free
6 // software; you can redistribute it and/or modify it under the
7 // terms of the GNU General Public License as published by the
8 // Free Software Foundation; either version 3, or (at your option)
9 // any later version.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
16 // You should have received a copy of the GNU General Public License along
17 // with this library; see the file COPYING3. If not see
18 // <http://www.gnu.org/licenses/>.
21 // { dg-do link }
22 // { dg-options "-D_XOPEN_SOURCE" { target *-*-freebsd* *-*-dragonfly* } }
24 #include <cmath>
26 int
27 test01()
29 float a = 1.f;
30 float b;
31 std::modf(a, &b);
32 return 0;
35 int
36 test02 ()
38 float a = 0.0f;
39 float b __attribute__((unused)) = std::acos(a);
40 return 0;
43 int
44 main()
46 test01();
47 test02();
48 return 0;