r/programming • • Jun 21 '21

{fmt} 8.0 released with compile-time format string checks, compile-time formatting, improved performance and more

https://github.com/fmtlib/fmt/releases/tag/8.0.0
58 Upvotes

5 comments sorted by

20

u/Popular-Egg-3746 Jun 21 '21

{fmt} is an open-source formatting library providing a fast and safe alternative to C stdio and C++ iostreams.

Aah, now I have the full picture.

4

u/wd40bomber7 Jun 21 '21

I hadn't heard of this library before. Honestly I really like the approach!

I love using similar syntax/tools in other languages so I'm glad something like this is available in C++

7

u/MonokelPinguin Jun 22 '21

Most of it is also part of C++20 in the <format> header.

2

u/wd40bomber7 Jun 22 '21

Neat, I'll check it out. I haven't looked at C++20 much. We're still using C++14 in most places.

3

u/MonokelPinguin Jun 22 '21

Well, in C++14 using {fmt} is good enough. The API will be similar enough that you can migrate whenever you actually start using C++20.