Re: [PATCH 4/8] libstdc++: Fix error handling in std::print

2024-02-27 Thread Tim Song
[print.fun] requires a system_error, but I don't think [ostream.formatted.print] does? On Tue, Feb 27, 2024 at 5:47 AM Jonathan Wakely wrote: > Tested x86_64-linux. Reviews invited. > > -- >8 -- > > The standard requires an exception if std::print fails to write to a > std::ostream. > > libstdc+

[PATCH 4/8] libstdc++: Fix error handling in std::print

2024-02-27 Thread Jonathan Wakely
Tested x86_64-linux. Reviews invited. -- >8 -- The standard requires an exception if std::print fails to write to a std::ostream. libstdc++-v3/ChangeLog: * include/std/ostream (vprint_nonunicode): Throw if stream state indicates writing failed. * testsuite/27_io/basic_os