News for hackers. Stuff that matters.
Re:F-strings for C++26 proposal [pdf] by chlorion on Monday February 03, 2025 @04:02AM (#42916316)
Being able to use string formatting without a heap is pretty cool.

Rusts string formatting machinery does not require any heap allocations at all, you can for example impl fmt::Write for a struct that writes directly to a serial console byte-by-byte with no allocations, and then you have access to all of rusts string formatting features available to print over a serial console!

I'm not sure about the horrifying and dangerous extensions part though, I'm not really a C++ expert so I don't know if there's a better way to do what they want to do.

There are no comments on this comment yet.