Closed
Description
The fmt()
macro is very useful to check if arguments are valid. As far as I can see, this is only possible for format
. E.g. (from the documentation):
std::string s = fmt::format(fmt("{:d}"), "foo"); // Produces compiler error
I would like to be able to use the macro also in format_to
, in order to avoid allocations from std::string
. For example
fmt::memory_buffer buf;
fmt::format_to(buf, fmt("{:d}"), "foo");
Is this planned, or do I miss something?
Thank you for your support and the great work on fmtlib!
Metadata
Metadata
Assignees
Labels
No labels