libstdc++: Add various missing exports [PR121373]

On Sat, Aug 02, 2025 at 09:05:07PM +0200, Jakub Jelinek wrote:
> Wonder how to automatically discover other missing exports (like in PR121373
> std::byteswap), maybe one could dig that stuff somehow from the raw
> dump (look for identifiers in std namespace (and perhaps inlined namespaces
> thereof at least) which don't start with underscore.

To answer that question, I wrote a simple plugin which just dumps the names
(which do not start with underscore) in std namespace (and its inlined
namespaces) and for non-inline namespaces in there which do not start with
underscore also recurses on those namespaces.

Plugin source in
https://gcc.gnu.org/pipermail/libstdc++/2025-August/062859.html

I went through it all now, using cppreference as a quick check for stuff
removed in C++17/C++20 and for everything added verified it is in
corresponding eel.is/c++-draft/*.syn etc. and looked it up in the libstdc++
headers for guarding macros.

2025-08-04  Jakub Jelinek  <jakub@redhat.com>
	    hexne  <printfne@gmail.com>

	PR libstdc++/121373
	* src/c++23/std.cc.in (std::ranges::shift_left,
	std::ranges::shift_right): Only export for C++23 and later.
	(std::ranges::fold_left_first_with_iter_result,
	std::ranges::fold_left_with_iter_result): Export.
	(std::byteswap): Export for C++23 and later.
	(std::ranges::iter_move, std::ranges::iter_swap): Export.
	(std::projected_value_t): Export for C++26 and later.
	(std::out_ptr_t, std::inout_ptr_t): Export.
	(std::ranges::iota_result): Export.
	(std::regex_constants): Export a lot of constants.
	(std::is_scoped_enum, std::is_scoped_enum_v): Export.

(cherry picked from commit 490c2c885ee5de1659d8339ea6bedd908acfacea)
1 file changed