El 04/11/2025 a las 20:19, Peter Dimov via Boost escribió:
Mungo Gill wrote:
In case anyone is curious how to implement support for <format> in boost::string_view by delegating to the formatter for std::string_view: https://godbolt.org/z/YsWKrEz3P
There's no way to portably forward-declare things in std (even if we discount the fact that this is explicitly called out as undefined behavior.)
No standard way, but there is a practial way using some tricks https://github.com/boostorg/move/blob/develop/include/boost/move/detail/std_... https://github.com/boostorg/container/blob/develop/include/boost/container/d... See your example using Boost.Move internal headers: https://godbolt.org/z/Eez6f9cf5 In spite of the "official UB" I think we should have a StdFwd library in Boost (or maybe some header doing the ugly stuff in Boost.Config). Best, Ion