On Thu, 21 May 2026 at 12:38, Tomasz Kaminski <[email protected]> wrote: > On Tue, May 19, 2026 at 7:27 PM Jonathan Wakely <[email protected]> wrote: >> diff --git a/libstdc++-v3/include/std/iosfwd >> b/libstdc++-v3/include/std/iosfwd >> index 42124ad30df4..41f82addef0b 100644 >> --- a/libstdc++-v3/include/std/iosfwd >> +++ b/libstdc++-v3/include/std/iosfwd >> @@ -39,222 +39,9 @@ >> >> #include <bits/requires_hosted.h> // iostreams >> >> -#include <bits/c++config.h> >> -#include <bits/stringfwd.h> // For string forward declarations. >> -#include <bits/postypes.h> >> - >> -namespace std _GLIBCXX_VISIBILITY(default) >> -{ >> -_GLIBCXX_BEGIN_NAMESPACE_VERSION >> - >> - /** >> - * @defgroup io I/O >> - * >> - * Nearly all of the I/O classes are parameterized on the type of >> - * characters they read and write. (The major exception is ios_base at >> - * the top of the hierarchy.) This is a change from pre-Standard >> - * streams, which were not templates. >> - * >> - * For ease of use and compatibility, all of the basic_* I/O-related >> - * classes are given typedef names for both of the builtin character >> - * widths (wide and narrow). The typedefs are the same as the >> - * pre-Standard names, for example: >> - * >> - * @code >> - * typedef basic_ifstream<char> ifstream; >> - * @endcode >> - * >> - * Because properly forward-declaring these classes can be difficult, you >> - * should not do it yourself. Instead, include the <iosfwd> >> - * header, which contains only declarations of all the I/O classes as >> - * well as the typedefs. Trying to forward-declare the typedefs >> - * themselves (e.g., <code>class ostream;</code>) is not valid ISO C++. >> - * >> - * For more specific declarations, see >> - * https://gcc.gnu.org/onlinedocs/libstdc++/manual/io.html#std.io.objects >> - * >> - * @{ >> - */ > > I think this comment should remain in the <iosfwd> header, and not > <bits/iosfwd,h>, > all declarations for the new subheaders are meant to be included.
OK, I'll move the @defgroup comment back to <iosfwd>, and use @ingroup in <bits/iosfwd.h>. > Should we already add entry about this to porting to? Because a lot of files, > will no longer provide foward declarations. There is no gcc-17/porting_to.html doc yet. I've already created one locally with this in it, so once the file exists, I'll get a merge conflict and add to it.
