Stl: What about <format> ?

Created on 27 Aug 2020  路  5Comments  路  Source: microsoft/STL

Sorry if this is the wrong place to ask.
My understanding was that a library implementation is coming soon.
Can't find it, however, nor any information.

Is there a time-frame?
Is it still recommended to use {fmt} for quite a while?

question resolved

Most helpful comment

As @miscco noted, @barcharcraz is working on <format>; #1232 is the first of what should be several PRs (we're using a feature branch feature/format to collect this work). #30 is the tracking issue for the feature (one of 24 remaining C++20 features). It's a big feature, so we can't promise when it'll be done, but we're working on it :smile_cat:

All 5 comments

You might want to have a look at #1232

Is it still recommended to use {fmt} for quite a while?

Note that std::format is not a fully drop in replacement. It doesn't have literals, a fmt::memory_buffer equivalent, or compile-time checking of the format string (although that will probably be something compilers implement in the future) so you should review or correct your usage to make sure that std::format fits it. fmt::memory_buffer, for example, will have to be replaced by your own memory buffer implementation, if you use it.

Thanks for the warning.
I was trying to avoid those (future) problems by using a current STL implementation which I believed to be open source.
I'm just unable to find the code.

As @miscco noted, @barcharcraz is working on <format>; #1232 is the first of what should be several PRs (we're using a feature branch feature/format to collect this work). #30 is the tracking issue for the feature (one of 24 remaining C++20 features). It's a big feature, so we can't promise when it'll be done, but we're working on it :smile_cat:

Got it, thx.

Was this page helpful?
0 / 5 - 0 ratings