1// Inspired by libstdc++/7680 & 26_numerics/c_math.cc, 2003-04-12 ljr
2
3// Copyright (C) 2003, 2009 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.
10
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.
15
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/>.
19
20
21// { dg-do link }
22// { dg-options "-D_XOPEN_SOURCE" { target *-*-freebsd* } }
23
24#include <cmath>
25
26int
27test01()
28{
29  float a = 1.f;
30  float b;
31  std::modf(a, &b);
32  return 0;
33}
34
35int
36test02 ()
37{
38  float a = 0.0f;
39  float b __attribute__((unused)) = std::acos(a);
40  return 0;
41}
42
43int
44main()
45{
46  test01();
47  test02();
48  return 0;
49}
50