1  // Copyright (C) 2017-2023 Free Software Foundation, Inc.
       2  //
       3  // This file is part of the GNU ISO C++ Library.  This library is free
       4  // software; you can redistribute it and/or modify it under the
       5  // terms of the GNU General Public License as published by the
       6  // Free Software Foundation; either version 3, or (at your option)
       7  // any later version.
       8  
       9  // This library is distributed in the hope that it will be useful,
      10  // but WITHOUT ANY WARRANTY; without even the implied warranty of
      11  // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      12  // GNU General Public License for more details.
      13  
      14  // You should have received a copy of the GNU General Public License along
      15  // with this library; see the file COPYING3.  If not see
      16  // <http://www.gnu.org/licenses/>.
      17  
      18  // { dg-options "-std=gnu++11" }
      19  
      20  #include <complex.h>
      21  
      22  // Should be equivalent to #include <complex>
      23  template class std::complex<double>;
      24  
      25  #if _GLIBCXX_HAVE_COMPLEX_H
      26  namespace test
      27  {
      28    using ::cacos;
      29    using ::casin;
      30    using ::catan;
      31    using ::ccos;
      32    using ::csin;
      33    using ::ctan;
      34    using ::ccosh;
      35    using ::csinh;
      36    using ::ctanh;
      37    using ::cexp;
      38    using ::clog;
      39    using ::cabs;
      40    using ::cpow;
      41    using ::csqrt;
      42    using ::carg;
      43    using ::cimag;
      44    using ::conj;
      45    using ::cproj;
      46    using ::creal;
      47  }
      48  #endif
      49  
      50  #ifdef complex
      51  # error "'complex' is defined as a macro by <complex.h> for -std=gnu++11"
      52  #endif