From f12ddb6249f83e89a323296cd561da85bcc57d8b Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Fri, 11 Sep 2015 13:25:43 +0100 Subject: [PATCH] Rationalise PCH headers and 17_intro/headers tests. PR libstdc++/64857 * doc/xml/manual/using.xml: Improve aggregate header documentation. * doc/html/manual/*: Regenerate. * include/precompiled/extc++.h: Include for C++11 and later and include more extension headers. * testsuite/17_intro/headers/c++1998/all_attributes.cc: Remove redundant header. * testsuite/17_intro/headers/c++200x/: Rename to c++2011. * testsuite/17_intro/headers/c++2014/all_attributes.cc: Remove redundant headers. * testsuite/17_intro/headers/c++2014/all_no_exceptions.cc: New. * testsuite/17_intro/headers/c++2014/all_no_rtti.cc: New. * testsuite/17_intro/headers/c++2014/all_pedantic_errors.cc: New. * testsuite/17_intro/headers/c++2014/operator_names.cc: New. * testsuite/17_intro/headers/c++2014/stdc++.cc: New. * testsuite/17_intro/headers/c++2014/stdc++_multiple_inclusion.cc: New. From-SVN: r227684 --- libstdc++-v3/ChangeLog | 18 +++ libstdc++-v3/doc/html/manual/using.html | 3 +- .../doc/html/manual/using_headers.html | 11 +- libstdc++-v3/doc/xml/manual/using.xml | 16 +-- libstdc++-v3/include/precompiled/extc++.h | 14 +++ .../headers/c++1998/all_attributes.cc | 1 - .../headers/{c++200x => c++2011}/42319.cc | 0 .../headers/{c++200x => c++2011}/67309.cc | 1 - .../{c++200x => c++2011}/all_attributes.cc | 1 - .../{c++200x => c++2011}/all_no_exceptions.cc | 0 .../{c++200x => c++2011}/all_no_rtti.cc | 0 .../all_pedantic_errors.cc | 0 .../{c++200x => c++2011}/operator_names.cc | 0 .../headers/{c++200x => c++2011}/stdc++.cc | 0 .../stdc++_multiple_inclusion.cc | 0 .../headers/c++2014/all_attributes.cc | 2 - .../headers/c++2014/all_no_exceptions.cc | 21 ++++ .../17_intro/headers/c++2014/all_no_rtti.cc | 21 ++++ .../headers/c++2014/all_pedantic_errors.cc | 21 ++++ .../headers/c++2014/operator_names.cc | 30 +++++ .../17_intro/headers/c++2014/stdc++.cc | 70 +++++++++++ .../c++2014/stdc++_multiple_inclusion.cc | 117 ++++++++++++++++++ 22 files changed, 330 insertions(+), 17 deletions(-) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/42319.cc (100%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/67309.cc (92%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/all_attributes.cc (94%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/all_no_exceptions.cc (100%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/all_no_rtti.cc (100%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/all_pedantic_errors.cc (100%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/operator_names.cc (100%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/stdc++.cc (100%) rename libstdc++-v3/testsuite/17_intro/headers/{c++200x => c++2011}/stdc++_multiple_inclusion.cc (100%) create mode 100644 libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_exceptions.cc create mode 100644 libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_rtti.cc create mode 100644 libstdc++-v3/testsuite/17_intro/headers/c++2014/all_pedantic_errors.cc create mode 100644 libstdc++-v3/testsuite/17_intro/headers/c++2014/operator_names.cc create mode 100644 libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++.cc create mode 100644 libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++_multiple_inclusion.cc diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 3bd33ba504c..03d24023bd0 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,5 +1,23 @@ 2015-09-11 Jonathan Wakely + PR libstdc++/64857 + * doc/xml/manual/using.xml: Improve aggregate header documentation. + * doc/html/manual/*: Regenerate. + * include/precompiled/extc++.h: Include for C++11 + and later and include more extension headers. + * testsuite/17_intro/headers/c++1998/all_attributes.cc: Remove + redundant header. + * testsuite/17_intro/headers/c++200x/: Rename to c++2011. + * testsuite/17_intro/headers/c++2014/all_attributes.cc: Remove + redundant headers. + * testsuite/17_intro/headers/c++2014/all_no_exceptions.cc: New. + * testsuite/17_intro/headers/c++2014/all_no_rtti.cc: New. + * testsuite/17_intro/headers/c++2014/all_pedantic_errors.cc: New. + * testsuite/17_intro/headers/c++2014/operator_names.cc: New. + * testsuite/17_intro/headers/c++2014/stdc++.cc: New. + * testsuite/17_intro/headers/c++2014/stdc++_multiple_inclusion.cc: + New. + PR libstdc++/58265 * doc/xml/manual/intro.xml: Document LWG 2063 and 2064 resolutions. * doc/html/manual/bugs.html: Regenerate. diff --git a/libstdc++-v3/doc/html/manual/using.html b/libstdc++-v3/doc/html/manual/using.html index cc5c65079b0..5888002028a 100644 --- a/libstdc++-v3/doc/html/manual/using.html +++ b/libstdc++-v3/doc/html/manual/using.html @@ -11,7 +11,8 @@ The standard library conforms to the dialect of C++ specified by the -std option passed to the compiler. By default, g++ is equivalent to - g++ -std=gnu++98. + g++ -std=gnu++14 since GCC 6, and + g++ -std=gnu++98 for older releases.

Table 3.1. C++ Command Options

Option FlagsDescription
-std=c++98 or -std=c++03 Use the 1998 ISO C++ standard plus amendments.
-std=gnu++98 or -std=gnu++03 As directly above, with GNU extensions.
-std=c++11Use the 2011 ISO C++ standard.
-std=gnu++11As directly above, with GNU extensions.
-std=c++14Use the 2014 ISO C++ standard.
-std=gnu++14As directly above, with GNU extensions.
-fexceptionsSee exception-free dialect
-frttiAs above, but RTTI-free dialect.
-pthread or -pthreadsFor ISO C++11 diff --git a/libstdc++-v3/doc/html/manual/using_headers.html b/libstdc++-v3/doc/html/manual/using_headers.html index 7e4d5be9136..bb147944ad9 100644 --- a/libstdc++-v3/doc/html/manual/using_headers.html +++ b/libstdc++-v3/doc/html/manual/using_headers.html @@ -74,12 +74,15 @@ of std::sinf, std::sin, and std::sinl.

Precompiled Headers

There are three base header files that are provided. They can be used to precompile the standard headers and extensions into binary -files that may the be used to speed compiles that use these headers. +files that may then be used to speed up compilations that use these headers.

  • stdc++.h

    Includes all standard headers. Actual content varies depending on -language dialect. +language dialect.

  • stdtr1c++.h

    Includes all of <stdc++.h>, and adds all the TR1 headers. -

  • extc++.h

    Includes all of <stdtr1c++.h>, and adds all the Extension headers. -

How to construct a .gch file from one of these base header files.

First, find the include directory for the compiler. One way to do +

  • extc++.h

    Includes all of <stdc++.h>, and adds all the Extension headers +(and in C++98 mode also adds all the TR1 headers by including all of +<stdtr1c++.h>). +

  • To construct a .gch file from one of these base header files, +first find the include directory for the compiler. One way to do this is:

     g++ -v hello.cc
     
    diff --git a/libstdc++-v3/doc/xml/manual/using.xml b/libstdc++-v3/doc/xml/manual/using.xml
    index bad49f20c61..2c8d179b489 100644
    --- a/libstdc++-v3/doc/xml/manual/using.xml
    +++ b/libstdc++-v3/doc/xml/manual/using.xml
    @@ -16,7 +16,8 @@
           The standard library conforms to the dialect of C++ specified by the
            option passed to the compiler.
           By default, g++ is equivalent to
    -      g++ -std=gnu++98.
    +      g++ -std=gnu++14 since GCC 6, and
    +      g++ -std=gnu++98 for older releases.
         
     
      
    @@ -718,7 +719,7 @@ and std::sinl.
     
     There are three base header files that are provided. They can be
     used to precompile the standard headers and extensions into binary
    -files that may the be used to speed compiles that use these headers.
    +files that may then be used to speed up compilations that use these headers.
     
     
     
    @@ -726,7 +727,7 @@ files that may the be used to speed compiles that use these headers.
     
       stdc++.h
     Includes all standard headers. Actual content varies depending on
    -language dialect.
    +language dialect.
     
     
     
    @@ -737,13 +738,14 @@ language dialect.
     extc++.h
    -Includes all of <stdtr1c++.h>, and adds all the Extension headers.
    +Includes all of <stdc++.h>, and adds all the Extension headers
    +(and in C++98 mode also adds all the TR1 headers by including all of
    +<stdtr1c++.h>).
     
     
    -How to construct a .gch file from one of these base header files.
    -
    -First, find the include directory for the compiler. One way to do
    +To construct a .gch file from one of these base header files,
    +first find the include directory for the compiler. One way to do
     this is:
     
     
    diff --git a/libstdc++-v3/include/precompiled/extc++.h b/libstdc++-v3/include/precompiled/extc++.h
    index de3775b36f5..8883e47fb0c 100644
    --- a/libstdc++-v3/include/precompiled/extc++.h
    +++ b/libstdc++-v3/include/precompiled/extc++.h
    @@ -28,15 +28,25 @@
     
     #if __cplusplus < 201103L
     #include 
    +#else
    +#include 
     #endif
     
     #include 
    +#if __cplusplus >= 201103L
    +# include 
    +#endif
    +#include 
     #include 
     #include 
     #include 
     #include 
    +#if __cplusplus >= 201103L
    +# include 
    +#endif
     #include 
     #include 
    +#include 
     #include 
     #include 
     #include 
    @@ -45,9 +55,13 @@
     #include 
     #include 
     #include 
    +#include 
     #include 
     #include 
     #include 
    +#if __cplusplus >= 201103L
    +# include 
    +#endif
     #include 
     #include 
     #include 
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++1998/all_attributes.cc b/libstdc++-v3/testsuite/17_intro/headers/c++1998/all_attributes.cc
    index 7bc7ffe868c..20107d2cccf 100644
    --- a/libstdc++-v3/testsuite/17_intro/headers/c++1998/all_attributes.cc
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++1998/all_attributes.cc
    @@ -35,7 +35,6 @@
     #define unused 1
     #endif
     
    -#include  // TODO: this is missing from 
     #include 
     
     int
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/42319.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/42319.cc
    similarity index 100%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/42319.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/42319.cc
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/67309.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/67309.cc
    similarity index 92%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/67309.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/67309.cc
    index 97df10f649f..409b38da59f 100644
    --- a/libstdc++-v3/testsuite/17_intro/headers/c++200x/67309.cc
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2011/67309.cc
    @@ -19,5 +19,4 @@
     // { dg-do compile }
     
     // libstdc++/67309
    -#include  // TODO: this is missing from 
     #include 
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/all_attributes.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/all_attributes.cc
    similarity index 94%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/all_attributes.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/all_attributes.cc
    index ae15f31b11c..8c3d0078576 100644
    --- a/libstdc++-v3/testsuite/17_intro/headers/c++200x/all_attributes.cc
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2011/all_attributes.cc
    @@ -34,7 +34,6 @@
     #define unused 1
     #endif
     
    -#include  // TODO: this is missing from 
     #include 
     
     int
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/all_no_exceptions.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/all_no_exceptions.cc
    similarity index 100%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/all_no_exceptions.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/all_no_exceptions.cc
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/all_no_rtti.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/all_no_rtti.cc
    similarity index 100%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/all_no_rtti.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/all_no_rtti.cc
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/all_pedantic_errors.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/all_pedantic_errors.cc
    similarity index 100%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/all_pedantic_errors.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/all_pedantic_errors.cc
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/operator_names.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/operator_names.cc
    similarity index 100%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/operator_names.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/operator_names.cc
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/stdc++.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/stdc++.cc
    similarity index 100%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/stdc++.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/stdc++.cc
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++200x/stdc++_multiple_inclusion.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2011/stdc++_multiple_inclusion.cc
    similarity index 100%
    rename from libstdc++-v3/testsuite/17_intro/headers/c++200x/stdc++_multiple_inclusion.cc
    rename to libstdc++-v3/testsuite/17_intro/headers/c++2011/stdc++_multiple_inclusion.cc
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_attributes.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_attributes.cc
    index c482fbd9c4d..c395e1dab75 100644
    --- a/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_attributes.cc
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_attributes.cc
    @@ -34,8 +34,6 @@
     #define unused 1
     #endif
     
    -#include  // TODO: this is missing from 
    -#include   // TODO: this is missing from 
     #include 
     
     int
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_exceptions.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_exceptions.cc
    new file mode 100644
    index 00000000000..b5157c8af0b
    --- /dev/null
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_exceptions.cc
    @@ -0,0 +1,21 @@
    +// { dg-do compile }
    +// { dg-options "-std=gnu++14 -fno-exceptions" }
    +
    +// Copyright (C) 2015 Free Software Foundation, Inc.
    +//
    +// This file is part of the GNU ISO C++ Library.  This library is free
    +// software; you can redistribute it and/or modify it under the
    +// terms of the GNU General Public License as published by the
    +// Free Software Foundation; either version 3, or (at your option)
    +// any later version.
    +
    +// This library is distributed in the hope that it will be useful,
    +// but WITHOUT ANY WARRANTY; without even the implied warranty of
    +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    +// GNU General Public License for more details.
    +
    +// You should have received a copy of the GNU General Public License along
    +// with this library; see the file COPYING3.  If not see
    +// .
    +
    +#include 
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_rtti.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_rtti.cc
    new file mode 100644
    index 00000000000..8b9fec7b3cf
    --- /dev/null
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_no_rtti.cc
    @@ -0,0 +1,21 @@
    +// { dg-do compile }
    +// { dg-options "-std=gnu++14 -fno-rtti" }
    +
    +// Copyright (C) 2015 Free Software Foundation, Inc.
    +//
    +// This file is part of the GNU ISO C++ Library.  This library is free
    +// software; you can redistribute it and/or modify it under the
    +// terms of the GNU General Public License as published by the
    +// Free Software Foundation; either version 3, or (at your option)
    +// any later version.
    +
    +// This library is distributed in the hope that it will be useful,
    +// but WITHOUT ANY WARRANTY; without even the implied warranty of
    +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    +// GNU General Public License for more details.
    +
    +// You should have received a copy of the GNU General Public License along
    +// with this library; see the file COPYING3.  If not see
    +// .
    +
    +#include 
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_pedantic_errors.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_pedantic_errors.cc
    new file mode 100644
    index 00000000000..742315d82df
    --- /dev/null
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/all_pedantic_errors.cc
    @@ -0,0 +1,21 @@
    +// { dg-do compile }
    +// { dg-options "-std=gnu++14 -pedantic-errors" }
    +
    +// Copyright (C) 2015 Free Software Foundation, Inc.
    +//
    +// This file is part of the GNU ISO C++ Library.  This library is free
    +// software; you can redistribute it and/or modify it under the
    +// terms of the GNU General Public License as published by the
    +// Free Software Foundation; either version 3, or (at your option)
    +// any later version.
    +
    +// This library is distributed in the hope that it will be useful,
    +// but WITHOUT ANY WARRANTY; without even the implied warranty of
    +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    +// GNU General Public License for more details.
    +
    +// You should have received a copy of the GNU General Public License along
    +// with this library; see the file COPYING3.  If not see
    +// .
    +
    +#include 
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/operator_names.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2014/operator_names.cc
    new file mode 100644
    index 00000000000..c347368954c
    --- /dev/null
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/operator_names.cc
    @@ -0,0 +1,30 @@
    +// { dg-do compile }
    +// { dg-options "-std=gnu++14 -fno-operator-names" }
    +
    +// Copyright (C) 2015 Free Software Foundation, Inc.
    +//
    +// This file is part of the GNU ISO C++ Library.  This library is free
    +// software; you can redistribute it and/or modify it under the
    +// terms of the GNU General Public License as published by the
    +// Free Software Foundation; either version 3, or (at your option)
    +// any later version.
    +
    +// This library is distributed in the hope that it will be useful,
    +// but WITHOUT ANY WARRANTY; without even the implied warranty of
    +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    +// GNU General Public License for more details.
    +
    +// You should have received a copy of the GNU General Public License along
    +// with this library; see the file COPYING3.  If not see
    +// .
    +
    +// libstdc++/47662
    +
    +// Avoid using PCH
    +#include 
    +#include 
    +#include 
    +#include 
    +
    +int or, xor, and;
    +
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++.cc
    new file mode 100644
    index 00000000000..0528b33a64d
    --- /dev/null
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++.cc
    @@ -0,0 +1,70 @@
    +// FreeBSD wants warning clean system headers:
    +// { dg-options "-Wall -Wsystem-headers" { target *-*-freebsd* *-*-dragonfly* } }
    +// { dg-options "-std=gnu++14" }
    +// { dg-do compile }
    +
    +// Copyright (C) 2015 Free Software Foundation, Inc.
    +//
    +// This file is part of the GNU ISO C++ Library.  This library is free
    +// software; you can redistribute it and/or modify it under the
    +// terms of the GNU General Public License as published by the
    +// Free Software Foundation; either version 3, or (at your option)
    +// any later version.
    +
    +// This library is distributed in the hope that it will be useful,
    +// but WITHOUT ANY WARRANTY; without even the implied warranty of
    +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    +// GNU General Public License for more details.
    +
    +// You should have received a copy of the GNU General Public License along
    +// with this library; see the file COPYING3.  If not see
    +// .
    +
    +// 17.4.1.2 Headers
    +
    +#include 
    +
    +// "C" compatibility headers
    +#include 
    +#ifdef _GLIBCXX_HAVE_COMPLEX_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_FENV_H
    +#include 
    +#endif
    +#include 
    +#ifdef _GLIBCXX_HAVE_INTTYPES_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_STDBOOL_H
    +#include 
    +#endif
    +#include 
    +#ifdef _GLIBCXX_HAVE_STDINT_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_TGMATH_H
    +#include 
    +#endif
    +#include 
    +#if __has_include()
    +#include 
    +#endif
    +#ifdef _GLIBCXX_HAVE_WCHAR_H
    +#include 
    +#endif
    +#ifdef _GLIBCXX_HAVE_WCTYPE_H
    +#include 
    +#endif
    diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++_multiple_inclusion.cc b/libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++_multiple_inclusion.cc
    new file mode 100644
    index 00000000000..67b51cee95c
    --- /dev/null
    +++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/stdc++_multiple_inclusion.cc
    @@ -0,0 +1,117 @@
    +// FreeBSD wants warning clean system headers:
    +// { dg-options "-Wall -Wsystem-headers" { target *-*-freebsd* *-*-dragonfly* } }
    +// { dg-options "-std=gnu++14" }
    +// { dg-do compile }
    +
    +// Copyright (C) 2015 Free Software Foundation, Inc.
    +//
    +// This file is part of the GNU ISO C++ Library.  This library is free
    +// software; you can redistribute it and/or modify it under the
    +// terms of the GNU General Public License as published by the
    +// Free Software Foundation; either version 3, or (at your option)
    +// any later version.
    +
    +// This library is distributed in the hope that it will be useful,
    +// but WITHOUT ANY WARRANTY; without even the implied warranty of
    +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    +// GNU General Public License for more details.
    +
    +// You should have received a copy of the GNU General Public License along
    +// with this library; see the file COPYING3.  If not see
    +// .
    +
    +// 17.4.1.2 Headers
    +
    +#include 
    +
    +// "C" compatibility headers
    +#include 
    +#ifdef _GLIBCXX_HAVE_COMPLEX_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_FENV_H
    +#include 
    +#endif
    +#include 
    +#ifdef _GLIBCXX_HAVE_INTTYPES_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_STDBOOL_H
    +#include 
    +#endif
    +#include 
    +#ifdef _GLIBCXX_HAVE_STDINT_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_TGMATH_H
    +#include 
    +#endif
    +#include 
    +#if __has_include()
    +#include 
    +#endif
    +#ifdef _GLIBCXX_HAVE_WCHAR_H
    +#include 
    +#endif
    +#ifdef _GLIBCXX_HAVE_WCTYPE_H
    +#include 
    +#endif
    +
    +#include 
    +
    +// "C" compatibility headers
    +#include 
    +#ifdef _GLIBCXX_HAVE_COMPLEX_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_FENV_H
    +#include 
    +#endif
    +#include 
    +#ifdef _GLIBCXX_HAVE_INTTYPES_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_STDBOOL_H
    +#include 
    +#endif
    +#include 
    +#ifdef _GLIBCXX_HAVE_STDINT_H
    +#include 
    +#endif
    +#include 
    +#include 
    +#include 
    +#ifdef _GLIBCXX_HAVE_TGMATH_H
    +#include 
    +#endif
    +#include 
    +#if __has_include()
    +#include 
    +#endif
    +#ifdef _GLIBCXX_HAVE_WCHAR_H
    +#include 
    +#endif
    +#ifdef _GLIBCXX_HAVE_WCTYPE_H
    +#include 
    +#endif
    -- 
    2.30.2