[libcxx-commits] [libcxx] [libc++] Add basic constant folding for std::format (PR #107197)

Mark de Wever via libcxx-commits libcxx-commits at lists.llvm.org
Sun Feb 2 03:08:15 PST 2025


================
@@ -447,10 +449,41 @@ format_to(_OutIt __out_it, wformat_string<_Args...> __fmt, _Args&&... __args) {
 }
 #  endif
 
+template <class _CharT>
----------------
mordante wrote:

Please add some documentation what this function does.
The code is not easy to understand and I don't think it does what I expect it to do.
Does the code optimize `std::format("{}", 42)`?

https://github.com/llvm/llvm-project/pull/107197


More information about the libcxx-commits mailing list