News for hackers. Stuff that matters.
Re:Type-Safe Printf for C by kazinator on Tuesday December 14, 2021 @05:51PM (#29559230)
It's a big mistake that the format language looks like that of printf.

If you use this in a big code base, there will still be the old printf all over the place.

Now you have to think: is this custom logging function here based on the safe printf from github, or is it vsprintf under the hood?

Re:Type-Safe Printf for C by tinkersleep on Wednesday December 15, 2021 @12:53PM (#29569276)
You are right, it was a poor decision. The format is not C compatible, and using the same sigil is dangerous when switching and this library's format is passed to standard printf. This started out as a drop-in replacement, but it isn't, and cannot be. The library should not encourage, but avoid accidental format string mistakes.

So thank you, this is fixed.