Closed rglarix closed 1 year ago
oops, fmt/ostream.h somehow was forgotten. sorry for the noise
sorry, but it seems that from 9.0.0 onward fmt::sprintf cannot format from operator << anymore for example https://godbolt.org/z/v7Pqd5nWa With 8.1.1 works, but not with 9.x
That's expected. ostream
interface is only compatible with format-like functions. It only happened to partially work in older versions with printf by accident.
Hi, we have been using fmtlib for many years, both as a replacement for sprintf, and more recently to (slowly) migrate to format. For several types we have defined ostream operator << methods, using it for both sprintf and format. It's quite a big project and moves rather slowly, we are now at 7.1.3 and would like to upgrade to the latest release. But we realized that operator << no longer works for sprintf. For us this is a big regression, because we have over 20,000 sprintfs, even though not all use a custom formatter. Is there any way to reintroduce the formatter from ostream << to sprintf as well?